36PortableServer::Servant
38 const PortableServer::ObjectId& oid,
39 PortableServer::POA_ptr poa
42 DB(20,
"ProxyPullConsumerManager::incarnate()")
49 PortableServer::POA_ptr parentPoa,
60 DB(20,
"~ProxyPullConsumerManager()")
65CosEventChannelAdmin::ProxyPullConsumer_ptr
70 CosEventChannelAdmin::_tc_ProxyPullConsumer->id()
102 CosEventChannelAdmin::ProxyPullConsumer_var
ppcv =
ppc->_this();
119 throw CORBA::BAD_PARAM();
120 if(!CORBA::is_nil(
_target) || !CORBA::is_nil(
_req))
121 throw CosEventChannelAdmin::AlreadyConnected();
133 DB(5,
"ProxyPullConsumer_i::disconnect_pull_consumer()");
134 eraseKey(
"SupplierAdmin/ProxyPullConsumer");
138 throw CORBA::OBJECT_NOT_EXIST(
145 CORBA::Request_var
req=
_target->_request(
"disconnect_pull_supplier");
146 _target=CosEventComm::PullSupplier::_nil();
147 req->send_deferred();
155 PortableServer::POA_ptr
poa,
167 DB(20,
"~ProxyPullConsumer_i()")
172 if(!CORBA::is_nil(
_req) &&
_req->poll_response())
176 CORBA::Environment_ptr
env =
_req->env();
178 if(!CORBA::is_nil(
env) &&
env->exception())
180 CORBA::Exception*
ex =
env->exception();
181 DB(10,
"ProxyPullConsumer got exception"
189 DB(2,
"Ignoring unrecognised response. operation:"<<
opname);
195 CORBA::Request_var
req=
_target->_request(
"disconnect_pull_supplier");
196 req->send_deferred();
199 _target=CosEventComm::PullSupplier::_nil();
200 eraseKey(
"SupplierAdmin/ProxyPullConsumer");
214 CORBA::NVList_ptr
args=
_req->arguments();
222 CORBA::Any::to_boolean
tb(
b);
230 CORBA::Any*
event =
new CORBA::Any();
231 _req->return_value() >>= (*event);
237 _req=CORBA::Request::_nil();
252 _req->add_out_arg(
"has_event")<<=CORBA::Any::from_boolean(1);
257 _req->set_return_type(CORBA::_tc_any);
258 _req->send_deferred();
#define HERE
Generates a string literal that describes the filename and line number.
#define OMNIEVENTS__DEBUG_REF_COUNTS__DEFN(C)
Defines debug versions of _add/remove_ref() for class C.
#define IFELSE_OMNIORB4(omniORB4_code, default_code)
#define IF_OMNIORB4(omniORB4_code)
T::_ptr_type createNarrowedReference(PortableServer::POA_ptr poa, const char *repositoryId)
Helper method that creates a new CORBA object and then narrows it to the appropriate type.
static bool exists()
Library code may create Event Service objects without the need for persistency.
Obtains an output stream to the active persistancy logfile, and locks it for exclusive access.
void deferredRequest(CORBA::Request_ptr req, Callback *callback=NULL)
Adopts the request and then stores it in _deferredRequests.
void reportObjectFailure(const char *here, CORBA::Object_ptr obj, CORBA::Exception *ex)
Called by omniEvents when an object has failed (fatal exception).
Base class for ServantActivator classes that manage Proxy servants.
void activate(const char *name)
Creates the Proxy-type's POA, and registers this object as its ServantManager.
set< Proxy * > _servants
The set of all active Proxies in this object's _managedPoa.
PortableServer::POA_var _managedPoa
The POA owned & managed by this object.
Base class for three of the four Proxy servants.
void basicOutput(ostream &os, const char *name, CORBA::Object_ptr target=CORBA::Object::_nil(), const char *extraAttributes=NULL)
Helper method for constructing persistency output.
void eraseKey(const char *name)
Helper method for constructing persistency output.
void disconnect()
Send disconnect_pull_supplier() to all connected PullSuppliers.
void triggerRequest()
For each connected proxy, if there is no request in progress, send a new request to the current opera...
void collect()
Collects events that have arrived at connected proxies.
PortableServer::Servant incarnate(const PortableServer::ObjectId &oid, PortableServer::POA_ptr poa)
list< CORBA::Any * > & _queue
OMNIEVENTS__DEBUG_REF_COUNTS__DECL CosEventChannelAdmin::ProxyPullConsumer_ptr createObject()
~ProxyPullConsumerManager()
ProxyPullConsumerManager(PortableServer::POA_ptr parentPoa, list< CORBA::Any * > &q)
Implementation of the ProxyPullConsumer interface.
void output(ostream &os)
Save this object's state to a stream.
void disconnect_pull_consumer()
CosEventComm::PullSupplier_var _target
int _exceptionCount
Only when two consecutive exceptions have been received from each mode, do we consider the connection...
void connect_pull_supplier(CosEventComm::PullSupplier_ptr pullSupplier)
ProxyPullConsumer_i(PortableServer::POA_ptr poa, list< CORBA::Any * > &q)
void reincarnate(const string &oid, const PersistNode &node)
Re-create a servant from information saved in the log file.
void triggerRequest()
When _req is NIL, sends out a new pull() or try_pull() call.
list< CORBA::Any * > & _queue
void collect()
Collects responses since the last trigger.
void activateObjectWithId(const char *oidStr)
Calls activate_object_with_id() to activate this servant in its POA.
void deactivateObject()
Calls deactivate_object() to deactivate this servant in its POA.