#include <ProxyPushConsumer.h>
Inheritance diagram for TAO_Notify_ProxyPushConsumer:


Public Member Functions | |
| TAO_Notify_ProxyPushConsumer (void) | |
| Constuctor. | |
| virtual | ~TAO_Notify_ProxyPushConsumer () |
| Destructor. | |
| virtual const char * | get_proxy_type_name (void) const |
| virtual void | load_attrs (const TAO_Notify::NVPList &attrs) |
Protected Member Functions | |
| virtual CosNotifyChannelAdmin::ProxyType | MyType () throw ( CORBA::SystemException ) |
| = CosNotifyChannelAdmin::ProxyPushConsumer methods | |
| virtual void | push (const CORBA::Any &data) throw ( CORBA::SystemException, CosEventComm::Disconnected ) |
| virtual void | connect_any_push_supplier (CosEventComm::PushSupplier_ptr push_supplier) throw ( CORBA::SystemException, CosEventChannelAdmin::AlreadyConnected ) |
| virtual void | disconnect_push_consumer () throw ( CORBA::SystemException ) |
Private Types | |
| typedef TAO_Notify_ProxyConsumer_T< POA_CosNotifyChannelAdmin::ProxyPushConsumer > | SuperClass |
Private Member Functions | |
| virtual void | release (void) |
| Release. | |
Friends | |
| class | TAO_Notify_Builder |
|
|
Definition at line 44 of file ProxyPushConsumer.h. |
|
|
Constuctor.
Definition at line 15 of file ProxyPushConsumer.cpp.
00016 {
00017 }
|
|
|
Destructor.
Definition at line 19 of file ProxyPushConsumer.cpp.
00020 {
00021 }
|
|
|
Definition at line 61 of file ProxyPushConsumer.cpp. References ACE_CHECK, ACE_ENV_ARG_PARAMETER, ACE_ENV_SINGLE_ARG_PARAMETER, ACE_NEW_THROW_EX, and TAO_Notify_PushSupplier::init(). Referenced by load_attrs().
00066 {
00067 // Convert Supplier to Base Type
00068 TAO_Notify_PushSupplier *supplier;
00069 ACE_NEW_THROW_EX (supplier,
00070 TAO_Notify_PushSupplier (this),
00071 CORBA::NO_MEMORY ());
00072
00073 supplier->init (push_supplier ACE_ENV_ARG_PARAMETER);
00074 ACE_CHECK;
00075
00076 this->connect (supplier ACE_ENV_ARG_PARAMETER);
00077 ACE_CHECK;
00078 this->self_change (ACE_ENV_SINGLE_ARG_PARAMETER);
00079 }
|
|
|
Definition at line 81 of file ProxyPushConsumer.cpp. References ACE_CHECK, and ACE_ENV_SINGLE_ARG_PARAMETER.
00085 {
00086 TAO_Notify_ProxyPushConsumer::Ptr guard( this );
00087 this->destroy (ACE_ENV_SINGLE_ARG_PARAMETER);
00088 ACE_CHECK;
00089 this->self_change (ACE_ENV_SINGLE_ARG_PARAMETER);
00090 }
|
|
|
Implements TAO_Notify_Proxy. Definition at line 93 of file ProxyPushConsumer.cpp.
00094 {
00095 return "proxy_push_consumer";
00096 }
|
|
|
Load our attributes. Each derived type should call the superclass load first before loading its own attributes. Reimplemented from TAO_Notify_Object. Definition at line 99 of file ProxyPushConsumer.cpp. References ACE_ASSERT, ACE_CATCHALL, ACE_CString, ACE_DECLARE_NEW_CORBA_ENV, ACE_ENDTRY, ACE_ENV_ARG_PARAMETER, ACE_TRY, ACE_TRY_CHECK, connect_any_push_supplier(), TAO_Singleton< TYPE, ACE_LOCK >::instance(), and TAO_Notify::NVPList::load().
00100 {
00101 SuperClass::load_attrs(attrs);
00102 ACE_CString ior;
00103 if (attrs.load("PeerIOR", ior))
00104 {
00105 CORBA::ORB_var orb = TAO_Notify_PROPERTIES::instance()->orb();
00106 ACE_DECLARE_NEW_CORBA_ENV;
00107 ACE_TRY
00108 {
00109 ACE_TRY_CHECK;
00110 CosNotifyComm::PushSupplier_var ps = CosNotifyComm::PushSupplier::_nil();
00111 if ( ior.length() > 0 )
00112 {
00113 CORBA::Object_var obj =
00114 orb->string_to_object(ior.c_str() ACE_ENV_ARG_PARAMETER);
00115 ACE_TRY_CHECK;
00116 ps = CosNotifyComm::PushSupplier::_unchecked_narrow(obj.in() ACE_ENV_ARG_PARAMETER);
00117 ACE_TRY_CHECK;
00118 }
00119 // minor hack: suppress generating subscription updates during reload.
00120 bool save_updates = this->updates_off_;
00121 this->updates_off_ = true;
00122 this->connect_any_push_supplier(ps.in() ACE_ENV_ARG_PARAMETER);
00123 ACE_TRY_CHECK;
00124 this->updates_off_ = save_updates;
00125 }
00126 ACE_CATCHALL
00127 {
00128 ACE_ASSERT(0);
00129 }
00130 ACE_ENDTRY;
00131 }
00132 }
|
|
|
= CosNotifyChannelAdmin::ProxyPushConsumer methods
Definition at line 31 of file ProxyPushConsumer.cpp.
00035 {
00036 return CosNotifyChannelAdmin::PUSH_ANY;
00037 }
|
|
|
Definition at line 40 of file ProxyPushConsumer.cpp. References ACE_ENV_ARG_PARAMETER, and ACE_THROW.
00045 {
00046 // Check if we should proceed at all.
00047 if (this->admin_properties().reject_new_events () == 1
00048 && this->admin_properties().queue_full ())
00049 ACE_THROW (CORBA::IMP_LIMIT ());
00050
00051 if (this->is_connected () == 0)
00052 {
00053 ACE_THROW (CosEventComm::Disconnected ());
00054 }
00055
00056 TAO_Notify_AnyEvent_No_Copy event (any);
00057 this->push_i (&event ACE_ENV_ARG_PARAMETER);
00058 }
|
|
|
Release.
Implements TAO_Notify_Refcountable. Definition at line 24 of file ProxyPushConsumer.cpp.
00025 {
00026 delete this;
00027 //@@ inform factory
00028 }
|
|
|
Reimplemented from TAO_Notify_Object. Definition at line 45 of file ProxyPushConsumer.h. |
1.3.6