TAO_CEC_EventChannel Class Reference

The CosEventChannelAdmin::EventChannel implementation. More...

#include <CEC_EventChannel.h>

Collaboration diagram for TAO_CEC_EventChannel:

Collaboration graph
[legend]
List of all members.

Public Types

typedef ACE_Hash_Map_Manager_Ex<
PortableServer::ServantBase *,
unsigned int, ServantBaseHash,
ACE_Equal_To< PortableServer::ServantBase * >,
TAO_SYNCH_MUTEX
ServantRetryMap

Public Member Functions

 TAO_CEC_EventChannel (const TAO_CEC_EventChannel_Attributes &attributes, TAO_CEC_Factory *factory=0, int own_factory=0)
virtual ~TAO_CEC_EventChannel (void)
 destructor
virtual void activate (void)
virtual void shutdown (void)
TAO_CEC_Dispatchingdispatching (void) const
 Access the dispatching module....
TAO_CEC_ConsumerAdminconsumer_admin (void) const
 Access the consumer admin implementation.
TAO_CEC_SupplierAdminsupplier_admin (void) const
 Access the supplier admin implementation.
TAO_CEC_ConsumerControlconsumer_control (void) const
 Access the consumer control strategy.
TAO_CEC_SupplierControlsupplier_control (void) const
 Access the supplier control strategy.
void create_proxy (TAO_CEC_ProxyPushSupplier *&)
 Create and destroy a ProxyPushSupplier.
void destroy_proxy (TAO_CEC_ProxyPushSupplier *)
void create_proxy (TAO_CEC_ProxyPullSupplier *&)
 Create and destroy a ProxyPullSupplier.
void destroy_proxy (TAO_CEC_ProxyPullSupplier *)
void create_proxy (TAO_CEC_ProxyPushConsumer *&)
 Create and destroy a ProxyPushConsumer.
void destroy_proxy (TAO_CEC_ProxyPushConsumer *)
void create_proxy (TAO_CEC_ProxyPullConsumer *&)
 Create and destroy a ProxyPushConsumer.
void destroy_proxy (TAO_CEC_ProxyPullConsumer *)
void create_proxy_collection (TAO_CEC_ProxyPushSupplier_Collection *&)
void destroy_proxy_collection (TAO_CEC_ProxyPushSupplier_Collection *)
void create_proxy_collection (TAO_CEC_ProxyPullSupplier_Collection *&)
void destroy_proxy_collection (TAO_CEC_ProxyPullSupplier_Collection *)
void create_proxy_collection (TAO_CEC_ProxyPushConsumer_Collection *&)
void destroy_proxy_collection (TAO_CEC_ProxyPushConsumer_Collection *)
void create_proxy_collection (TAO_CEC_ProxyPullConsumer_Collection *&)
void destroy_proxy_collection (TAO_CEC_ProxyPullConsumer_Collection *)
PortableServer::POA_ptr supplier_poa (void)
 Access the supplier and consumer POAs from the factory.
PortableServer::POA_ptr consumer_poa (void)
ACE_Lockcreate_consumer_lock (void)
void destroy_consumer_lock (ACE_Lock *)
ACE_Lockcreate_supplier_lock (void)
void destroy_supplier_lock (ACE_Lock *)
virtual void connected (TAO_CEC_ProxyPushConsumer *)
virtual void reconnected (TAO_CEC_ProxyPushConsumer *)
virtual void disconnected (TAO_CEC_ProxyPushConsumer *)
virtual void connected (TAO_CEC_ProxyPullConsumer *)
virtual void reconnected (TAO_CEC_ProxyPullConsumer *)
virtual void disconnected (TAO_CEC_ProxyPullConsumer *)
virtual void connected (TAO_CEC_ProxyPushSupplier *)
virtual void reconnected (TAO_CEC_ProxyPushSupplier *)
virtual void disconnected (TAO_CEC_ProxyPushSupplier *)
virtual void connected (TAO_CEC_ProxyPullSupplier *)
virtual void reconnected (TAO_CEC_ProxyPullSupplier *)
virtual void disconnected (TAO_CEC_ProxyPullSupplier *)
int consumer_reconnect (void) const
 Can the consumers reconnect to the EC?
int supplier_reconnect (void) const
 Can the suppliers reconnect to the EC?
int disconnect_callbacks (void) const
virtual CosEventChannelAdmin::ConsumerAdmin_ptr for_consumers (void)
virtual CosEventChannelAdmin::SupplierAdmin_ptr for_suppliers (void)
virtual void destroy (void)
 Commit suicide.
ServantRetryMapget_servant_retry_map (void)
CORBA::Policy_ptr create_roundtrip_timeout_policy (const ACE_Time_Value &timeout)
 Forwarded to the factory.

Private Attributes

PortableServer::POA_var supplier_poa_
PortableServer::POA_var consumer_poa_
TAO_CEC_Factoryfactory_
int own_factory_
 Flag that indicates if we own the factory.
TAO_CEC_Dispatchingdispatching_
 The dispatching "module".
TAO_CEC_Pulling_Strategypulling_strategy_
 The pulling strategy.
TAO_CEC_ConsumerAdminconsumer_admin_
 The ConsumerAdmin implementation.
TAO_CEC_SupplierAdminsupplier_admin_
 The SupplierAdmin implementation.
int consumer_reconnect_
 Consumer/Supplier reconnection flags.
int supplier_reconnect_
int disconnect_callbacks_
 If not zero we send callbacks when a proxy is disconnected.
TAO_CEC_ConsumerControlconsumer_control_
TAO_CEC_SupplierControlsupplier_control_
ServantRetryMap retry_map_

Classes

class  ServantBaseHash

Detailed Description

The CosEventChannelAdmin::EventChannel implementation.

This class is the Mediator between all the classes in the EC implementation, its main task is to redirect the messages to the right components, to hold and manage the lifetime of the long lived objects (Timer_Module, SupplierAdmin, ConsumerAdmin and Dispatching) and to provide a simpler interface to the CEC_Factory.

Definition at line 104 of file CEC_EventChannel.h.


Member Typedef Documentation

typedef ACE_Hash_Map_Manager_Ex<PortableServer::ServantBase*, unsigned int, ServantBaseHash, ACE_Equal_To<PortableServer::ServantBase*>, TAO_SYNCH_MUTEX> TAO_CEC_EventChannel::ServantRetryMap

Definition at line 119 of file CEC_EventChannel.h.


Constructor & Destructor Documentation

TAO_BEGIN_VERSIONED_NAMESPACE_DECL TAO_CEC_EventChannel::TAO_CEC_EventChannel ( const TAO_CEC_EventChannel_Attributes attributes,
TAO_CEC_Factory factory = 0,
int  own_factory = 0 
)

constructor If <own_factory> is not 0 it assumes ownership of the factory. If the factory is <nil> it uses the Service_Configurator to load the Factory, if not found it uses TAO_CEC_Default_Resource_Factory

Definition at line 21 of file CEC_EventChannel.cpp.

References ACE_ASSERT, and ACE_Dynamic_Service< TYPE >::instance().

00024   : supplier_poa_ (PortableServer::POA::_duplicate (attr.supplier_poa)),
00025     consumer_poa_ (PortableServer::POA::_duplicate (attr.consumer_poa)),
00026     factory_ (factory),
00027     own_factory_ (own_factory),
00028     consumer_reconnect_ (attr.consumer_reconnect),
00029     supplier_reconnect_ (attr.supplier_reconnect),
00030     disconnect_callbacks_ (attr.disconnect_callbacks)
00031 {
00032   if (this->factory_ == 0)
00033     {
00034       this->factory_ =
00035         ACE_Dynamic_Service<TAO_CEC_Factory>::instance ("CEC_Factory");
00036       this->own_factory_ = 0;
00037       ACE_ASSERT (this->factory_ != 0);
00038     }
00039 
00040   this->dispatching_ =
00041     this->factory_->create_dispatching (this);
00042   this->pulling_strategy_ =
00043     this->factory_->create_pulling_strategy (this);
00044   this->consumer_admin_ =
00045     this->factory_->create_consumer_admin (this);
00046   this->supplier_admin_ =
00047     this->factory_->create_supplier_admin (this);
00048   this->consumer_control_ =
00049     this->factory_->create_consumer_control (this);
00050   this->supplier_control_ =
00051     this->factory_->create_supplier_control (this);
00052 }

TAO_CEC_EventChannel::~TAO_CEC_EventChannel ( void   )  [virtual]

destructor

Definition at line 54 of file CEC_EventChannel.cpp.

References consumer_admin_, consumer_control_, TAO_CEC_Factory::destroy_consumer_admin(), TAO_CEC_Factory::destroy_consumer_control(), TAO_CEC_Factory::destroy_dispatching(), TAO_CEC_Factory::destroy_pulling_strategy(), TAO_CEC_Factory::destroy_supplier_admin(), TAO_CEC_Factory::destroy_supplier_control(), dispatching_, factory_, pulling_strategy_, supplier_admin_, and supplier_control_.

00055 {
00056   this->factory_->destroy_dispatching (this->dispatching_);
00057   this->dispatching_ = 0;
00058 
00059   this->factory_->destroy_pulling_strategy (this->pulling_strategy_);
00060   this->pulling_strategy_ = 0;
00061 
00062   this->factory_->destroy_consumer_admin (this->consumer_admin_);
00063   this->consumer_admin_ = 0;
00064   this->factory_->destroy_supplier_admin (this->supplier_admin_);
00065   this->supplier_admin_ = 0;
00066 
00067   this->factory_->destroy_consumer_control (this->consumer_control_);
00068   this->consumer_control_ = 0;
00069   this->factory_->destroy_supplier_control (this->supplier_control_);
00070   this->supplier_control_ = 0;
00071 
00072   if (this->own_factory_)
00073     delete this->factory_;
00074 }


Member Function Documentation

void TAO_CEC_EventChannel::activate ( void   )  [virtual]

Start the internal threads (if any), etc. After this call the EC can be used.

Definition at line 77 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierControl::activate(), TAO_CEC_ConsumerControl::activate(), TAO_CEC_Pulling_Strategy::activate(), TAO_CEC_Dispatching::activate(), consumer_control_, dispatching_, pulling_strategy_, and supplier_control_.

Referenced by TAO_CEC_Event_Loader::create_object().

00078 {
00079   this->dispatching_->activate ();
00080   this->pulling_strategy_->activate ();
00081   this->consumer_control_->activate ();
00082   this->supplier_control_->activate ();
00083 }

void TAO_CEC_EventChannel::connected ( TAO_CEC_ProxyPullSupplier  )  [virtual]

Definition at line 165 of file CEC_EventChannel.cpp.

References TAO_CEC_ConsumerAdmin::connected(), and consumer_admin_.

00166 {
00167   this->consumer_admin_->connected (supplier);
00168 }

void TAO_CEC_EventChannel::connected ( TAO_CEC_ProxyPushSupplier  )  [virtual]

Used to inform the EC that a Supplier has connected or disconnected from it.

Definition at line 147 of file CEC_EventChannel.cpp.

References TAO_CEC_ConsumerAdmin::connected(), and consumer_admin_.

00148 {
00149   this->consumer_admin_->connected (supplier);
00150 }

void TAO_CEC_EventChannel::connected ( TAO_CEC_ProxyPullConsumer  )  [virtual]

Definition at line 129 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierAdmin::connected(), and supplier_admin_.

00130 {
00131   this->supplier_admin_->connected (consumer);
00132 }

void TAO_CEC_EventChannel::connected ( TAO_CEC_ProxyPushConsumer  )  [virtual]

Used to inform the EC that a Consumer has connected or disconnected from it.

Definition at line 111 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierAdmin::connected(), and supplier_admin_.

Referenced by TAO_CEC_ProxyPullSupplier::connect_pull_consumer(), TAO_CEC_ProxyPullConsumer::connect_pull_supplier(), TAO_CEC_ProxyPushSupplier::connect_push_consumer(), and TAO_CEC_ProxyPushConsumer::connect_push_supplier().

00112 {
00113   this->supplier_admin_->connected (consumer);
00114 }

ACE_INLINE TAO_CEC_ConsumerAdmin * TAO_CEC_EventChannel::consumer_admin ( void   )  const

Access the consumer admin implementation.

Definition at line 26 of file CEC_EventChannel.inl.

References consumer_admin_.

Referenced by TAO_CEC_ProxyPushConsumer::push(), and TAO_CEC_Reactive_ConsumerControl::query_consumers().

00027 {
00028   return this->consumer_admin_;
00029 }

ACE_INLINE TAO_CEC_ConsumerControl * TAO_CEC_EventChannel::consumer_control ( void   )  const

Access the consumer control strategy.

Definition at line 38 of file CEC_EventChannel.inl.

References consumer_control_.

Referenced by TAO_CEC_ProxyPushSupplier::push_to_consumer(), and TAO_CEC_ProxyPushSupplier::reactive_push_to_consumer().

00039 {
00040   return this->consumer_control_;
00041 }

ACE_INLINE PortableServer::POA_ptr TAO_CEC_EventChannel::consumer_poa ( void   ) 

Definition at line 152 of file CEC_EventChannel.inl.

Referenced by shutdown().

00153 {
00154   return PortableServer::POA::_duplicate (this->consumer_poa_.in ());
00155 }

ACE_INLINE int TAO_CEC_EventChannel::consumer_reconnect ( void   )  const

Can the consumers reconnect to the EC?

Definition at line 182 of file CEC_EventChannel.inl.

References consumer_reconnect_.

00183 {
00184   return this->consumer_reconnect_;
00185 }

ACE_INLINE ACE_Lock * TAO_CEC_EventChannel::create_consumer_lock ( void   ) 

Locking strategies for the ProxyPushConsumer and ProxyPushSupplier objects

Definition at line 158 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_consumer_lock(), and factory_.

00159 {
00160   return this->factory_->create_consumer_lock ();
00161 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy ( TAO_CEC_ProxyPullConsumer *&   ) 

Create and destroy a ProxyPushConsumer.

Definition at line 86 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_pull_consumer(), and factory_.

00087 {
00088   x = this->factory_->create_proxy_pull_consumer (this);
00089 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy ( TAO_CEC_ProxyPushConsumer *&   ) 

Create and destroy a ProxyPushConsumer.

Definition at line 74 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_push_consumer(), and factory_.

00075 {
00076   x = this->factory_->create_proxy_push_consumer (this);
00077 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy ( TAO_CEC_ProxyPullSupplier *&   ) 

Create and destroy a ProxyPullSupplier.

Definition at line 62 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_pull_supplier(), and factory_.

00063 {
00064   x = this->factory_->create_proxy_pull_supplier (this);
00065 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy ( TAO_CEC_ProxyPushSupplier *&   ) 

Create and destroy a ProxyPushSupplier.

Definition at line 50 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_push_supplier(), and factory_.

00051 {
00052   x = this->factory_->create_proxy_push_supplier (this);
00053 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy_collection ( TAO_CEC_ProxyPullConsumer_Collection *&   ) 

Definition at line 110 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_pull_consumer_collection(), and factory_.

00111 {
00112   x = this->factory_->create_proxy_pull_consumer_collection (this);
00113 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy_collection ( TAO_CEC_ProxyPushConsumer_Collection *&   ) 

Create and destroy a the collections used to store Proxy*Consumers

Definition at line 98 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_push_consumer_collection(), and factory_.

00099 {
00100   x = this->factory_->create_proxy_push_consumer_collection (this);
00101 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy_collection ( TAO_CEC_ProxyPullSupplier_Collection *&   ) 

Definition at line 134 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_pull_supplier_collection(), and factory_.

00135 {
00136   x = this->factory_->create_proxy_pull_supplier_collection (this);
00137 }

ACE_INLINE void TAO_CEC_EventChannel::create_proxy_collection ( TAO_CEC_ProxyPushSupplier_Collection *&   ) 

Create and destroy a the collections used to store Proxy*Suppliers

Definition at line 122 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_proxy_push_supplier_collection(), and factory_.

00123 {
00124   x = this->factory_->create_proxy_push_supplier_collection (this);
00125 }

CORBA::Policy_ptr TAO_CEC_EventChannel::create_roundtrip_timeout_policy ( const ACE_Time_Value timeout  ) 

Forwarded to the factory.

Definition at line 201 of file CEC_EventChannel.cpp.

00202 {
00203   return this->factory_->create_roundtrip_timeout_policy (timeout);
00204 }

ACE_INLINE ACE_Lock * TAO_CEC_EventChannel::create_supplier_lock ( void   ) 

Definition at line 170 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::create_supplier_lock(), and factory_.

00171 {
00172   return this->factory_->create_supplier_lock ();
00173 }

void TAO_CEC_EventChannel::destroy ( void   )  [virtual]

Commit suicide.

Definition at line 195 of file CEC_EventChannel.cpp.

References shutdown().

Referenced by TAO_CEC_Event_Loader::fini().

00196 {
00197   this->shutdown ();
00198 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_consumer_lock ( ACE_Lock  ) 

Definition at line 164 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_consumer_lock(), and factory_.

Referenced by TAO_CEC_ProxyPullConsumer::~TAO_CEC_ProxyPullConsumer(), and TAO_CEC_ProxyPushConsumer::~TAO_CEC_ProxyPushConsumer().

00165 {
00166   this->factory_->destroy_consumer_lock (x);
00167 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy ( TAO_CEC_ProxyPullConsumer  ) 

Definition at line 92 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_pull_consumer(), and factory_.

00093 {
00094   this->factory_->destroy_proxy_pull_consumer (consumer);
00095 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy ( TAO_CEC_ProxyPushConsumer  ) 

Definition at line 80 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_push_consumer(), and factory_.

00081 {
00082   this->factory_->destroy_proxy_push_consumer (consumer);
00083 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy ( TAO_CEC_ProxyPullSupplier  ) 

Definition at line 68 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_pull_supplier(), and factory_.

00069 {
00070   this->factory_->destroy_proxy_pull_supplier (supplier);
00071 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy ( TAO_CEC_ProxyPushSupplier  ) 

Definition at line 56 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_push_supplier(), and factory_.

Referenced by TAO_CEC_ProxyPushSupplier::_decr_refcnt(), TAO_CEC_ProxyPushConsumer::_decr_refcnt(), TAO_CEC_ProxyPullSupplier::_decr_refcnt(), TAO_CEC_ProxyPullConsumer::_decr_refcnt(), and TAO_CEC_ProxyPushConsumer_Guard::~TAO_CEC_ProxyPushConsumer_Guard().

00057 {
00058   this->factory_->destroy_proxy_push_supplier (supplier);
00059 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy_collection ( TAO_CEC_ProxyPullConsumer_Collection  ) 

Definition at line 116 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_pull_consumer_collection(), and factory_.

00117 {
00118   this->factory_->destroy_proxy_pull_consumer_collection (x);
00119 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy_collection ( TAO_CEC_ProxyPushConsumer_Collection  ) 

Definition at line 104 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_push_consumer_collection(), and factory_.

00105 {
00106   this->factory_->destroy_proxy_push_consumer_collection (x);
00107 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy_collection ( TAO_CEC_ProxyPullSupplier_Collection  ) 

Definition at line 140 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_pull_supplier_collection(), and factory_.

00141 {
00142   this->factory_->destroy_proxy_pull_supplier_collection (x);
00143 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_proxy_collection ( TAO_CEC_ProxyPushSupplier_Collection  ) 

Definition at line 128 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_proxy_push_supplier_collection(), and factory_.

00129 {
00130   this->factory_->destroy_proxy_push_supplier_collection (x);
00131 }

ACE_INLINE void TAO_CEC_EventChannel::destroy_supplier_lock ( ACE_Lock  ) 

Definition at line 176 of file CEC_EventChannel.inl.

References TAO_CEC_Factory::destroy_supplier_lock(), and factory_.

Referenced by TAO_CEC_ProxyPullSupplier::~TAO_CEC_ProxyPullSupplier(), and TAO_CEC_ProxyPushSupplier::~TAO_CEC_ProxyPushSupplier().

00177 {
00178   this->factory_->destroy_supplier_lock (x);
00179 }

ACE_INLINE int TAO_CEC_EventChannel::disconnect_callbacks ( void   )  const

Should we send callback disconnect messages when a proxy is disconnected by the client

Definition at line 194 of file CEC_EventChannel.inl.

References disconnect_callbacks_.

00195 {
00196   return this->disconnect_callbacks_;
00197 }

void TAO_CEC_EventChannel::disconnected ( TAO_CEC_ProxyPullSupplier  )  [virtual]

Definition at line 177 of file CEC_EventChannel.cpp.

References consumer_admin_, and TAO_CEC_ConsumerAdmin::disconnected().

00178 {
00179   this->consumer_admin_->disconnected (supplier);
00180 }

void TAO_CEC_EventChannel::disconnected ( TAO_CEC_ProxyPushSupplier  )  [virtual]

Definition at line 159 of file CEC_EventChannel.cpp.

References consumer_admin_, and TAO_CEC_ConsumerAdmin::disconnected().

00160 {
00161   this->consumer_admin_->disconnected (supplier);
00162 }

void TAO_CEC_EventChannel::disconnected ( TAO_CEC_ProxyPullConsumer  )  [virtual]

Definition at line 141 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierAdmin::disconnected(), and supplier_admin_.

00142 {
00143   this->supplier_admin_->disconnected (consumer);
00144 }

void TAO_CEC_EventChannel::disconnected ( TAO_CEC_ProxyPushConsumer  )  [virtual]

Definition at line 123 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierAdmin::disconnected(), and supplier_admin_.

Referenced by TAO_CEC_ProxyPullConsumer::connect_pull_supplier(), TAO_CEC_ProxyPushConsumer::connect_push_supplier(), TAO_CEC_ProxyPullConsumer::disconnect_pull_consumer(), TAO_CEC_ProxyPullSupplier::disconnect_pull_supplier(), TAO_CEC_ProxyPushConsumer::disconnect_push_consumer(), and TAO_CEC_ProxyPushSupplier::disconnect_push_supplier().

00124 {
00125   this->supplier_admin_->disconnected (consumer);
00126 }

ACE_INLINE TAO_CEC_Dispatching * TAO_CEC_EventChannel::dispatching ( void   )  const

Access the dispatching module....

Definition at line 20 of file CEC_EventChannel.inl.

References dispatching_.

Referenced by TAO_CEC_ProxyPushSupplier::push(), and TAO_CEC_ProxyPushSupplier::push_nocopy().

00021 {
00022   return this->dispatching_;
00023 }

CosEventChannelAdmin::ConsumerAdmin_ptr TAO_CEC_EventChannel::for_consumers ( void   )  [virtual]

The default implementation is: this->consumer_admin ()->_this (env);

Definition at line 183 of file CEC_EventChannel.cpp.

References consumer_admin_.

00184 {
00185   return this->consumer_admin_->_this ();
00186 }

CosEventChannelAdmin::SupplierAdmin_ptr TAO_CEC_EventChannel::for_suppliers ( void   )  [virtual]

The default implementation is: this->supplier_admin ()->_this (env);

Definition at line 189 of file CEC_EventChannel.cpp.

References supplier_admin_.

00190 {
00191   return this->supplier_admin_->_this ();
00192 }

ACE_INLINE TAO_CEC_EventChannel::ServantRetryMap & TAO_CEC_EventChannel::get_servant_retry_map ( void   ) 

Definition at line 200 of file CEC_EventChannel.inl.

References retry_map_.

Referenced by TAO_CEC_ProxyPullConsumer::~TAO_CEC_ProxyPullConsumer(), TAO_CEC_ProxyPullSupplier::~TAO_CEC_ProxyPullSupplier(), TAO_CEC_ProxyPushConsumer::~TAO_CEC_ProxyPushConsumer(), and TAO_CEC_ProxyPushSupplier::~TAO_CEC_ProxyPushSupplier().

00201 {
00202   return this->retry_map_;
00203 }

void TAO_CEC_EventChannel::reconnected ( TAO_CEC_ProxyPullSupplier  )  [virtual]

Definition at line 171 of file CEC_EventChannel.cpp.

References consumer_admin_, and TAO_CEC_ConsumerAdmin::reconnected().

00172 {
00173   this->consumer_admin_->reconnected (supplier);
00174 }

void TAO_CEC_EventChannel::reconnected ( TAO_CEC_ProxyPushSupplier  )  [virtual]

Definition at line 153 of file CEC_EventChannel.cpp.

References consumer_admin_, and TAO_CEC_ConsumerAdmin::reconnected().

00154 {
00155   this->consumer_admin_->reconnected (supplier);
00156 }

void TAO_CEC_EventChannel::reconnected ( TAO_CEC_ProxyPullConsumer  )  [virtual]

Definition at line 135 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierAdmin::reconnected(), and supplier_admin_.

00136 {
00137   this->supplier_admin_->reconnected (consumer);
00138 }

void TAO_CEC_EventChannel::reconnected ( TAO_CEC_ProxyPushConsumer  )  [virtual]

Definition at line 117 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierAdmin::reconnected(), and supplier_admin_.

Referenced by TAO_CEC_ProxyPullSupplier::connect_pull_consumer(), and TAO_CEC_ProxyPushSupplier::connect_push_consumer().

00118 {
00119   this->supplier_admin_->reconnected (consumer);
00120 }

void TAO_CEC_EventChannel::shutdown ( void   )  [virtual]

Shutdown any internal threads, cleanup all the internal structures, flush all the messages, etc.

Definition at line 86 of file CEC_EventChannel.cpp.

References TAO_CEC_SupplierAdmin::_default_POA(), TAO_CEC_ConsumerAdmin::_default_POA(), consumer_admin_, consumer_control_, consumer_poa(), dispatching_, pulling_strategy_, TAO_CEC_ConsumerAdmin::shutdown(), TAO_CEC_SupplierAdmin::shutdown(), TAO_CEC_ConsumerControl::shutdown(), TAO_CEC_SupplierControl::shutdown(), TAO_CEC_Pulling_Strategy::shutdown(), TAO_CEC_Dispatching::shutdown(), supplier_admin_, supplier_control_, and supplier_poa().

Referenced by destroy().

00087 {
00088   this->dispatching_->shutdown ();
00089   this->pulling_strategy_->shutdown ();
00090   this->supplier_control_->shutdown ();
00091   this->consumer_control_->shutdown ();
00092 
00093   PortableServer::POA_var consumer_poa =
00094     this->consumer_admin_->_default_POA ();
00095   PortableServer::ObjectId_var consumer_id =
00096     consumer_poa->servant_to_id (this->consumer_admin_);
00097   consumer_poa->deactivate_object (consumer_id.in ());
00098 
00099   PortableServer::POA_var supplier_poa =
00100     this->supplier_admin_->_default_POA ();
00101   PortableServer::ObjectId_var supplier_id =
00102     supplier_poa->servant_to_id (this->supplier_admin_);
00103   supplier_poa->deactivate_object (supplier_id.in ());
00104 
00105   this->supplier_admin_->shutdown ();
00106 
00107   this->consumer_admin_->shutdown ();
00108 }

ACE_INLINE TAO_CEC_SupplierAdmin * TAO_CEC_EventChannel::supplier_admin ( void   )  const

Access the supplier admin implementation.

Definition at line 32 of file CEC_EventChannel.inl.

References supplier_admin_.

Referenced by TAO_CEC_Reactive_Pulling_Strategy::handle_timeout(), and TAO_CEC_Reactive_SupplierControl::query_suppliers().

00033 {
00034   return this->supplier_admin_;
00035 }

ACE_INLINE TAO_CEC_SupplierControl * TAO_CEC_EventChannel::supplier_control ( void   )  const

Access the supplier control strategy.

Definition at line 44 of file CEC_EventChannel.inl.

References supplier_control_.

Referenced by TAO_CEC_Reactive_Pulling_Strategy::handle_timeout(), and TAO_CEC_ProxyPullConsumer::try_pull_from_supplier().

00045 {
00046   return this->supplier_control_;
00047 }

ACE_INLINE PortableServer::POA_ptr TAO_CEC_EventChannel::supplier_poa ( void   ) 

Access the supplier and consumer POAs from the factory.

Definition at line 146 of file CEC_EventChannel.inl.

Referenced by shutdown().

00147 {
00148   return PortableServer::POA::_duplicate (this->supplier_poa_.in ());
00149 }

ACE_INLINE int TAO_CEC_EventChannel::supplier_reconnect ( void   )  const

Can the suppliers reconnect to the EC?

Definition at line 188 of file CEC_EventChannel.inl.

References supplier_reconnect_.

00189 {
00190   return this->supplier_reconnect_;
00191 }


Member Data Documentation

TAO_CEC_ConsumerAdmin* TAO_CEC_EventChannel::consumer_admin_ [private]

The ConsumerAdmin implementation.

Definition at line 273 of file CEC_EventChannel.h.

Referenced by connected(), consumer_admin(), disconnected(), for_consumers(), reconnected(), shutdown(), and ~TAO_CEC_EventChannel().

TAO_CEC_ConsumerControl* TAO_CEC_EventChannel::consumer_control_ [private]

Strategies to disconnect misbehaving or destroyed consumers and suppliers

Definition at line 287 of file CEC_EventChannel.h.

Referenced by activate(), consumer_control(), shutdown(), and ~TAO_CEC_EventChannel().

PortableServer::POA_var TAO_CEC_EventChannel::consumer_poa_ [private]

Definition at line 254 of file CEC_EventChannel.h.

int TAO_CEC_EventChannel::consumer_reconnect_ [private]

Consumer/Supplier reconnection flags.

Definition at line 279 of file CEC_EventChannel.h.

Referenced by consumer_reconnect().

int TAO_CEC_EventChannel::disconnect_callbacks_ [private]

If not zero we send callbacks when a proxy is disconnected.

Definition at line 283 of file CEC_EventChannel.h.

Referenced by disconnect_callbacks().

TAO_CEC_Dispatching* TAO_CEC_EventChannel::dispatching_ [private]

The dispatching "module".

Definition at line 267 of file CEC_EventChannel.h.

Referenced by activate(), dispatching(), shutdown(), and ~TAO_CEC_EventChannel().

TAO_CEC_Factory* TAO_CEC_EventChannel::factory_ [private]

This is the abstract factory that creates all the objects that compose an event channel, the event channel simply acts as a Mediator among them.

Definition at line 261 of file CEC_EventChannel.h.

Referenced by create_consumer_lock(), create_proxy(), create_proxy_collection(), create_supplier_lock(), destroy_consumer_lock(), destroy_proxy(), destroy_proxy_collection(), destroy_supplier_lock(), and ~TAO_CEC_EventChannel().

int TAO_CEC_EventChannel::own_factory_ [private]

Flag that indicates if we own the factory.

Definition at line 264 of file CEC_EventChannel.h.

TAO_CEC_Pulling_Strategy* TAO_CEC_EventChannel::pulling_strategy_ [private]

The pulling strategy.

Definition at line 270 of file CEC_EventChannel.h.

Referenced by activate(), shutdown(), and ~TAO_CEC_EventChannel().

ServantRetryMap TAO_CEC_EventChannel::retry_map_ [private]

Definition at line 290 of file CEC_EventChannel.h.

Referenced by get_servant_retry_map().

TAO_CEC_SupplierAdmin* TAO_CEC_EventChannel::supplier_admin_ [private]

The SupplierAdmin implementation.

Definition at line 276 of file CEC_EventChannel.h.

Referenced by connected(), disconnected(), for_suppliers(), reconnected(), shutdown(), supplier_admin(), and ~TAO_CEC_EventChannel().

TAO_CEC_SupplierControl* TAO_CEC_EventChannel::supplier_control_ [private]

Definition at line 288 of file CEC_EventChannel.h.

Referenced by activate(), shutdown(), supplier_control(), and ~TAO_CEC_EventChannel().

PortableServer::POA_var TAO_CEC_EventChannel::supplier_poa_ [private]

The POAs used to activate "supplier-side" and "consumer-side" objects.

Definition at line 253 of file CEC_EventChannel.h.

int TAO_CEC_EventChannel::supplier_reconnect_ [private]

Definition at line 280 of file CEC_EventChannel.h.

Referenced by supplier_reconnect().


The documentation for this class was generated from the following files:
Generated on Tue Feb 2 17:44:58 2010 for TAO_CosEvent by  doxygen 1.4.7