TAO_Notify_ProxySupplier_T< SERVANT_TYPE > Class Template Reference

#include <ProxySupplier_T.h>

Inheritance diagram for TAO_Notify_ProxySupplier_T< SERVANT_TYPE >:

Inheritance graph
[legend]
Collaboration diagram for TAO_Notify_ProxySupplier_T< SERVANT_TYPE >:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 TAO_Notify_ProxySupplier_T (void)
 Constructor.
 ~TAO_Notify_ProxySupplier_T ()
 Destructor.
virtual void admin_types_changed (const CosNotification::EventTypeSeq &added, const CosNotification::EventTypeSeq &removed)
 Notification of subscriptions set at the admin.
virtual void forward_structured (const CosNotification::StructuredEvent &event)
virtual void forward_structured_no_filtering (const CosNotification::StructuredEvent &event)
 POA_Notify_Internal::Event_Forwarder method.
virtual void forward_any (const CORBA::Any &event)
 POA_Notify_Internal::Event_Forwarder method.
virtual void forward_any_no_filtering (const CORBA::Any &event)
 POA_Notify_Internal::Event_Forwarder method.

Protected Member Functions

virtual CosNotifyChannelAdmin::ConsumerAdmin_ptr MyAdmin ()
virtual void suspend_connection ()
virtual void resume_connection ()
virtual CosNotifyFilter::MappingFilter_ptr priority_filter ()
virtual void priority_filter (CosNotifyFilter::MappingFilter_ptr priority_filter)
virtual CosNotifyFilter::MappingFilter_ptr lifetime_filter ()
virtual void lifetime_filter (CosNotifyFilter::MappingFilter_ptr lifetime_filter)
virtual CosNotification::EventTypeSeqobtain_offered_types (CosNotifyChannelAdmin::ObtainInfoMode mode)
virtual void subscription_change (const CosNotification::EventTypeSeq &added, const CosNotification::EventTypeSeq &removed)

Protected Attributes

CORBA::Boolean is_suspended_

Detailed Description

template<class SERVANT_TYPE>
class TAO_Notify_ProxySupplier_T< SERVANT_TYPE >

Definition at line 33 of file ProxySupplier_T.h.


Constructor & Destructor Documentation

template<class SERVANT_TYPE>
TAO_BEGIN_VERSIONED_NAMESPACE_DECL TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::TAO_Notify_ProxySupplier_T ( void   ) 

Constructor.

Definition at line 20 of file ProxySupplier_T.cpp.

00021   : is_suspended_ (0)
00022 {
00023 }

template<class SERVANT_TYPE>
TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::~TAO_Notify_ProxySupplier_T (  ) 

Destructor.

Definition at line 26 of file ProxySupplier_T.cpp.

00027 {
00028 }


Member Function Documentation

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::admin_types_changed ( const CosNotification::EventTypeSeq added,
const CosNotification::EventTypeSeq removed 
) [virtual]

Notification of subscriptions set at the admin.

Implements TAO_Notify_Proxy.

Definition at line 31 of file ProxySupplier_T.cpp.

References TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::subscription_change().

00033 {
00034   this->subscription_change (added, removed);
00035 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::forward_any ( const CORBA::Any &  event  )  [virtual]

POA_Notify_Internal::Event_Forwarder method.

Definition at line 58 of file ProxySupplier_T.cpp.

References TAO_Notify_Object::execute_task().

00059 {
00060   TAO_Notify_AnyEvent_No_Copy event (any);
00061 
00062   TAO_Notify_Method_Request_Dispatch_No_Copy request (&event, this, 1);
00063 
00064   this->execute_task (request);
00065 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::forward_any_no_filtering ( const CORBA::Any &  event  )  [virtual]

POA_Notify_Internal::Event_Forwarder method.

Definition at line 68 of file ProxySupplier_T.cpp.

References TAO_Notify_Object::execute_task().

00069 {
00070   TAO_Notify_AnyEvent_No_Copy event(any);
00071 
00072   TAO_Notify_Method_Request_Dispatch_No_Copy request (&event, this, 0);
00073 
00074   this->execute_task (request);
00075 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::forward_structured ( const CosNotification::StructuredEvent event  )  [virtual]

= POA_Notify_Internal methods POA_Notify_Internal::Event_Forwarder method

Definition at line 38 of file ProxySupplier_T.cpp.

References TAO_Notify_Object::execute_task().

00039 {
00040   TAO_Notify_StructuredEvent_No_Copy event (notification);
00041 
00042   TAO_Notify_Method_Request_Dispatch_No_Copy request (&event, this, 1);
00043 
00044   this->execute_task (request);
00045 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::forward_structured_no_filtering ( const CosNotification::StructuredEvent event  )  [virtual]

POA_Notify_Internal::Event_Forwarder method.

Definition at line 48 of file ProxySupplier_T.cpp.

References TAO_Notify_Object::execute_task().

00049 {
00050   TAO_Notify_StructuredEvent_No_Copy event(notification);
00051 
00052   TAO_Notify_Method_Request_Dispatch_No_Copy request (&event, this, 0);
00053 
00054   this->execute_task (request);
00055 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::lifetime_filter ( CosNotifyFilter::MappingFilter_ptr  lifetime_filter  )  [protected, virtual]

Definition at line 166 of file ProxySupplier_T.cpp.

00167 {
00168   throw CORBA::NO_IMPLEMENT ();
00169 }

template<class SERVANT_TYPE>
CosNotifyFilter::MappingFilter_ptr TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::lifetime_filter (  )  [protected, virtual]

Definition at line 160 of file ProxySupplier_T.cpp.

00161 {
00162   throw CORBA::NO_IMPLEMENT ();
00163 }

template<class SERVANT_TYPE>
CosNotifyChannelAdmin::ConsumerAdmin_ptr TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::MyAdmin (  )  [protected, virtual]

Definition at line 134 of file ProxySupplier_T.cpp.

References TAO_Notify_ProxySupplier::consumer_admin(), TAO_Pseudo_Var_T< T >::in(), and TAO_Notify_Object::ref().

00135 {
00136   CosNotifyChannelAdmin::ConsumerAdmin_var ret;
00137 
00138   CORBA::Object_var object = this->consumer_admin().ref ();
00139 
00140   ret = CosNotifyChannelAdmin::ConsumerAdmin::_narrow (object.in ());
00141 
00142   return ret._retn ();
00143 }

template<class SERVANT_TYPE>
CosNotification::EventTypeSeq * TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::obtain_offered_types ( CosNotifyChannelAdmin::ObtainInfoMode  mode  )  [protected, virtual]

Definition at line 78 of file ProxySupplier_T.cpp.

References TAO_Notify_Proxy::obtain_types().

00079 {
00080   return this->obtain_types (mode, this->event_manager().offered_types ());
00081 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::priority_filter ( CosNotifyFilter::MappingFilter_ptr  priority_filter  )  [protected, virtual]

Definition at line 154 of file ProxySupplier_T.cpp.

00155 {
00156   throw CORBA::NO_IMPLEMENT ();
00157 }

template<class SERVANT_TYPE>
CosNotifyFilter::MappingFilter_ptr TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::priority_filter (  )  [protected, virtual]

Definition at line 148 of file ProxySupplier_T.cpp.

00149 {
00150   throw CORBA::NO_IMPLEMENT ();
00151 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::resume_connection (  )  [protected, virtual]

Definition at line 118 of file ProxySupplier_T.cpp.

References ACE_GUARD_THROW_EX, TAO_Notify_ProxySupplier::consumer(), TAO_Notify_Consumer::resume(), and TAO_SYNCH_MUTEX.

00119 {
00120   {
00121     ACE_GUARD_THROW_EX (TAO_SYNCH_MUTEX, ace_mon, this->lock_, CORBA::INTERNAL ());
00122 
00123     if (this->is_connected () == 0)
00124       throw CosNotifyChannelAdmin::NotConnected ();
00125 
00126     if (this->consumer()->is_suspended () == 0)
00127       throw CosNotifyChannelAdmin::ConnectionAlreadyActive ();
00128   }
00129 
00130   this->consumer()->resume ();
00131 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::subscription_change ( const CosNotification::EventTypeSeq added,
const CosNotification::EventTypeSeq removed 
) [protected, virtual]

Definition at line 84 of file ProxySupplier_T.cpp.

References ACE_GUARD_THROW_EX, TAO_Notify_EventTypeSeq::add_and_remove(), TAO_Notify_Object::event_manager(), TAO_Notify_Proxy::subscribed_types_, TAO_Notify_Event_Manager::subscription_change(), and TAO_SYNCH_MUTEX.

Referenced by TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::admin_types_changed().

00086 {
00087   TAO_Notify_EventTypeSeq seq_added (added);
00088   TAO_Notify_EventTypeSeq seq_removed (removed);
00089 
00090   {
00091     ACE_GUARD_THROW_EX (TAO_SYNCH_MUTEX, ace_mon, this->lock_,
00092                         CORBA::INTERNAL ());
00093 
00094     this->subscribed_types_.add_and_remove (seq_added, seq_removed);
00095   }
00096 
00097   this->event_manager().subscription_change (this, seq_added, seq_removed);
00098 }

template<class SERVANT_TYPE>
void TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::suspend_connection (  )  [protected, virtual]

Definition at line 101 of file ProxySupplier_T.cpp.

References ACE_GUARD_THROW_EX, TAO_Notify_ProxySupplier::consumer(), TAO_Notify::Topology_Object::self_change(), TAO_Notify_Consumer::suspend(), and TAO_SYNCH_MUTEX.

00102 {
00103   {
00104     ACE_GUARD_THROW_EX (TAO_SYNCH_MUTEX, ace_mon, this->lock_, CORBA::INTERNAL ());
00105 
00106     if (this->is_connected () == 0)
00107       throw CosNotifyChannelAdmin::NotConnected ();
00108 
00109     if (this->consumer()->is_suspended () == 1)
00110       throw CosNotifyChannelAdmin::ConnectionAlreadyInactive ();
00111   }
00112 
00113   this->consumer()->suspend ();
00114   this->self_change ();
00115 }


Member Data Documentation

template<class SERVANT_TYPE>
CORBA::Boolean TAO_Notify_ProxySupplier_T< SERVANT_TYPE >::is_suspended_ [protected]

Definition at line 60 of file ProxySupplier_T.h.


The documentation for this class was generated from the following files:
Generated on Tue Feb 2 17:46:27 2010 for TAO_CosNotification by  doxygen 1.4.7