blob: 7801ed6dc99f313745bc269c67d41a7636311ff5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
|
/* -*- C++ -*- */
/**
* @file Properties.h
*
* $Id$
*
* @author Pradeep Gore <pradeep@oomworks.com>
*
*
*/
#ifndef TAO_Notify_PROPERTIES_H
#define TAO_Notify_PROPERTIES_H
#include /**/ "ace/pre.h"
#include "notify_serv_export.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
#include "tao/TAO_Singleton.h"
#include "tao/ORB.h"
#include "tao/PortableServer/PortableServer.h"
#include "orbsvcs/CosNotificationC.h"
class TAO_Notify_Factory;
class TAO_Notify_Builder;
/**
* @class TAO_Notify_Properties
*
* @brief Global properties that strategize Notify's run-time behaviour.
*
*/
class TAO_Notify_Serv_Export TAO_Notify_Properties
{
friend class TAO_Singleton<TAO_Notify_Properties, TAO_SYNCH_MUTEX>;
public:
/// Constuctor
TAO_Notify_Properties (void);
/// Destructor
~TAO_Notify_Properties ();
// = Property Accessors
TAO_Notify_Factory* factory (void);
void factory (TAO_Notify_Factory* factory);
TAO_Notify_Builder* builder (void);
void builder (TAO_Notify_Builder* builder);
CORBA::ORB_ptr orb (void);
void orb (CORBA::ORB_ptr orb);
PortableServer::POA_ptr default_poa (void);
void default_poa (PortableServer::POA_ptr default_poa);
CORBA::Boolean asynch_updates (void);
void asynch_updates (CORBA::Boolean asynch_updates);
bool allow_reconnect (void);
void allow_reconnect (bool b);
// Turn on/off update messages.
CORBA::Boolean updates (void);
void updates (CORBA::Boolean updates);
// The QoS Property that must be applied to each newly created Event Channel
const CosNotification::QoSProperties& default_event_channel_qos_properties (void);
// Set the default EC QoS Property.
void default_event_channel_qos_properties (const CosNotification::QoSProperties &ec_qos);
// The QoS Property that must be applied to each newly created Supplier Admin
const CosNotification::QoSProperties& default_supplier_admin_qos_properties (void);
// Set the default SA QoS Property.
void default_supplier_admin_qos_properties (const CosNotification::QoSProperties &sa_qos);
// The QoS Property that must be applied to each newly created Consumer Admin
const CosNotification::QoSProperties& default_consumer_admin_qos_properties (void);
// Set the default CA QoS Property.
void default_consumer_admin_qos_properties (const CosNotification::QoSProperties &ca_qos);
// The QoS Property that must be applied to each newly created Proxy Supplier
const CosNotification::QoSProperties& default_proxy_supplier_qos_properties (void);
// Set the default PS QoS Property.
void default_proxy_supplier_qos_properties (const CosNotification::QoSProperties &ps_qos);
// The QoS Property that must be applied to each newly created Proxy Consumer
const CosNotification::QoSProperties& default_proxy_consumer_qos_properties (void);
// Set the default PC QoS Property.
void default_proxy_consumer_qos_properties (const CosNotification::QoSProperties &pc_qos);
protected:
/// Object Factory
TAO_Notify_Factory* factory_;
/// Object Builder
TAO_Notify_Builder* builder_;
/// ORB
CORBA::ORB_var orb_;
// POA
PortableServer::POA_var default_poa_;
/// True if send asynch updates.
CORBA::Boolean asynch_updates_;
/// True if clients can reconnect to proxies.
bool allow_reconnect_;
/// True if updates are enabled (default).
CORBA::Boolean updates_;
/// The Update period for updates.
ACE_Time_Value update_period_;
/// The default EC QoS Properties.
CosNotification::QoSProperties ec_qos_;
/// The default SA QoS Properties.
CosNotification::QoSProperties sa_qos_;
/// The default CA QoS Properties.
CosNotification::QoSProperties ca_qos_;
/// The default PS QoS Properties.
CosNotification::QoSProperties ps_qos_;
/// The default PC QoS Properties.
CosNotification::QoSProperties pc_qos_;
};
typedef TAO_Singleton<TAO_Notify_Properties, TAO_SYNCH_MUTEX> TAO_Notify_PROPERTIES;
TAO_NOTIFY_SERV_SINGLETON_DECLARE (TAO_Singleton, TAO_Notify_Properties, TAO_SYNCH_MUTEX)
#if defined (__ACE_INLINE__)
#include "Properties.inl"
#endif /* __ACE_INLINE__ */
#include /**/ "ace/post.h"
#endif /* TAO_Notify_PROPERTIES_H */
|