summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/orbsvcs/FtRtEvent/Utils/FTEC_Gateway.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/orbsvcs/orbsvcs/FtRtEvent/Utils/FTEC_Gateway.cpp')
-rw-r--r--TAO/orbsvcs/orbsvcs/FtRtEvent/Utils/FTEC_Gateway.cpp189
1 files changed, 71 insertions, 118 deletions
diff --git a/TAO/orbsvcs/orbsvcs/FtRtEvent/Utils/FTEC_Gateway.cpp b/TAO/orbsvcs/orbsvcs/FtRtEvent/Utils/FTEC_Gateway.cpp
index afbbaf3d051..f36a3765d6c 100644
--- a/TAO/orbsvcs/orbsvcs/FtRtEvent/Utils/FTEC_Gateway.cpp
+++ b/TAO/orbsvcs/orbsvcs/FtRtEvent/Utils/FTEC_Gateway.cpp
@@ -24,7 +24,7 @@ public:
~FTEC_Gateway_ConsumerAdmin();
// = The RtecEventChannelAdmin::ConsumerAdmin methods...
virtual RtecEventChannelAdmin::ProxyPushSupplier_ptr
- obtain_push_supplier (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+ obtain_push_supplier (void)
ACE_THROW_SPEC ((CORBA::SystemException));
FTEC_Gateway_Impl* impl_;
};
@@ -37,7 +37,7 @@ public:
~FTEC_Gateway_SupplierAdmin();
// = The RtecEventChannelAdmin::SupplierAdmin methods...
virtual RtecEventChannelAdmin::ProxyPushConsumer_ptr
- obtain_push_consumer (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+ obtain_push_consumer (void)
ACE_THROW_SPEC ((CORBA::SystemException));
FTEC_Gateway_Impl* impl_;
};
@@ -51,16 +51,15 @@ public:
// = The RtecEventChannelAdmin::ProxyPushSupplier methods...
virtual void connect_push_consumer (
RtecEventComm::PushConsumer_ptr push_consumer,
- const RtecEventChannelAdmin::ConsumerQOS &qos
- ACE_ENV_ARG_DECL_NOT_USED)
+ const RtecEventChannelAdmin::ConsumerQOS &qos)
ACE_THROW_SPEC ((CORBA::SystemException,
RtecEventChannelAdmin::AlreadyConnected,
RtecEventChannelAdmin::TypeError));
- virtual void disconnect_push_supplier (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+ virtual void disconnect_push_supplier (void)
ACE_THROW_SPEC ((CORBA::SystemException));
- virtual void suspend_connection (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+ virtual void suspend_connection (void)
ACE_THROW_SPEC ((CORBA::SystemException));
- virtual void resume_connection (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+ virtual void resume_connection (void)
ACE_THROW_SPEC ((CORBA::SystemException));
FTEC_Gateway_Impl* impl_;
};
@@ -72,17 +71,15 @@ public:
FTEC_Gateway_ProxyPushConsumer(FTEC_Gateway_Impl* impl);
~FTEC_Gateway_ProxyPushConsumer();
- virtual void push (const RtecEventComm::EventSet & data
- ACE_ENV_ARG_DECL_WITH_DEFAULTS)
+ virtual void push (const RtecEventComm::EventSet & data)
ACE_THROW_SPEC ((CORBA::SystemException));
// = The RtecEventChannelAdmin::ProxyPushConsumer methods...
virtual void connect_push_supplier (
RtecEventComm::PushSupplier_ptr push_supplier,
- const RtecEventChannelAdmin::SupplierQOS& qos
- ACE_ENV_ARG_DECL_NOT_USED)
+ const RtecEventChannelAdmin::SupplierQOS& qos)
ACE_THROW_SPEC ((CORBA::SystemException,
RtecEventChannelAdmin::AlreadyConnected));
- virtual void disconnect_push_consumer (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+ virtual void disconnect_push_consumer (void)
ACE_THROW_SPEC ((CORBA::SystemException));
FTEC_Gateway_Impl* impl_;
@@ -93,10 +90,10 @@ class PushConsumerHandler : public POA_FtRtecEventComm::AMI_PushConsumerHandler
public:
PushConsumerHandler();
~PushConsumerHandler();
- virtual void push (ACE_ENV_SINGLE_ARG_DECL)
+ virtual void push (void)
ACE_THROW_SPEC ((CORBA::SystemException));
- virtual void push_excep (::Messaging::ExceptionHolder * excep_holder ACE_ENV_ARG_DECL)
+ virtual void push_excep (::Messaging::ExceptionHolder * excep_holder)
ACE_THROW_SPEC ((CORBA::SystemException));
};
@@ -106,13 +103,13 @@ public:
class Interceptor_Destoryer : public TAO_ORB_Core
{
public:
- inline static void execute(CORBA::ORB_ptr orb ACE_ENV_ARG_DECL) {
- static_cast<Interceptor_Destoryer*> (orb->orb_core())->do_it(ACE_ENV_SINGLE_ARG_PARAMETER);
+ inline static void execute(CORBA::ORB_ptr orb) {
+ static_cast<Interceptor_Destoryer*> (orb->orb_core())->do_it();
}
private:
Interceptor_Destoryer();
- inline void do_it(ACE_ENV_SINGLE_ARG_DECL) {
- destroy_interceptors(ACE_ENV_SINGLE_ARG_PARAMETER);
+ inline void do_it(void) {
+ destroy_interceptors();
};
};
@@ -158,7 +155,7 @@ FTEC_Gateway::~FTEC_Gateway()
}
RtecEventChannelAdmin::EventChannel_ptr
-FTEC_Gateway::activate(PortableServer::POA_ptr root_poa ACE_ENV_ARG_DECL)
+FTEC_Gateway::activate(PortableServer::POA_ptr root_poa)
{
PortableServer::POA_var poa;
PortableServer::POAManager_var mgr;
@@ -166,42 +163,30 @@ FTEC_Gateway::activate(PortableServer::POA_ptr root_poa ACE_ENV_ARG_DECL)
if (impl_->local_orb) {
int argc = 0;
char** argv = 0;
- impl_->orb = CORBA::ORB_init(argc, argv, "FTEC_GatewayORB"
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ impl_->orb = CORBA::ORB_init(argc, argv, "FTEC_GatewayORB");
- Interceptor_Destoryer::execute(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
+ Interceptor_Destoryer::execute(impl_->orb.in());
- poa = resolve_init<PortableServer::POA>(impl_->orb.in(), "RootPOA"
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ poa = resolve_init<PortableServer::POA>(impl_->orb.in(), "RootPOA");
- mgr = poa->the_POAManager(ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ mgr = poa->the_POAManager();
- mgr->activate(ACE_ENV_SINGLE_ARG_PARAMETER);
+ mgr->activate();
}
else {
poa = PortableServer::POA::_duplicate(root_poa);
- mgr = poa->the_POAManager(ACE_ENV_SINGLE_ARG_PARAMETER);
+ mgr = poa->the_POAManager();
}
- ACE_CHECK_RETURN(0);
PortableServer::IdUniquenessPolicy_var id_uniqueness_policy =
- poa->create_id_uniqueness_policy(PortableServer::MULTIPLE_ID
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ poa->create_id_uniqueness_policy(PortableServer::MULTIPLE_ID);
PortableServer::LifespanPolicy_var lifespan =
- poa->create_lifespan_policy(PortableServer::PERSISTENT
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ poa->create_lifespan_policy(PortableServer::PERSISTENT);
// create a USER_ID IdAssignmentPolicy object
PortableServer::IdAssignmentPolicy_var assign =
- poa->create_id_assignment_policy(PortableServer::USER_ID
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ poa->create_id_assignment_policy(PortableServer::USER_ID);
CORBA::PolicyList policy_list;
policy_list.length(3);
@@ -213,9 +198,7 @@ FTEC_Gateway::activate(PortableServer::POA_ptr root_poa ACE_ENV_ARG_DECL)
policy_list[2]=
PortableServer::IdAssignmentPolicy::_duplicate(assign.in());
- impl_->poa = poa->create_POA("gateway_poa", mgr.in(), policy_list
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ impl_->poa = poa->create_POA("gateway_poa", mgr.in(), policy_list);
id_uniqueness_policy->destroy();
lifespan->destroy();
@@ -227,79 +210,71 @@ FTEC_Gateway::activate(PortableServer::POA_ptr root_poa ACE_ENV_ARG_DECL)
RtecEventChannelAdmin::EventChannel_var gateway;
- activate_object_with_id(gateway.out(), impl_->poa.in(), this, oid ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ activate_object_with_id(gateway.out(), impl_->poa.in(), this, oid);
++oid[9];
activate_object_with_id(impl_->consumer_admin.out(),
impl_->poa.in(),
&impl_->consumer_admin_servant,
- oid ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ oid);
++oid[9];
activate_object_with_id(impl_->supplier_admin.out(),
impl_->poa.in(),
&impl_->supplier_admin_servant,
- oid ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ oid);
return gateway._retn();
}
//= The RtecEventChannelAdmin::EventChannel methods
RtecEventChannelAdmin::ConsumerAdmin_ptr
-FTEC_Gateway::for_consumers (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+FTEC_Gateway::for_consumers (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
return RtecEventChannelAdmin::ConsumerAdmin::_duplicate(impl_->consumer_admin.in());
}
RtecEventChannelAdmin::SupplierAdmin_ptr
-FTEC_Gateway::for_suppliers (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+FTEC_Gateway::for_suppliers (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
ACE_DEBUG((LM_DEBUG, "FTEC_Gateway::for_suppliers\n"));
return RtecEventChannelAdmin::SupplierAdmin::_duplicate(impl_->supplier_admin.in());
}
-void FTEC_Gateway::destroy (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+void FTEC_Gateway::destroy (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
impl_->ftec->destroy();
}
RtecEventChannelAdmin::Observer_Handle
-FTEC_Gateway::append_observer (RtecEventChannelAdmin::Observer_ptr observer
- ACE_ENV_ARG_DECL)
+FTEC_Gateway::append_observer (RtecEventChannelAdmin::Observer_ptr observer)
ACE_THROW_SPEC ((
CORBA::SystemException,
RtecEventChannelAdmin::EventChannel::SYNCHRONIZATION_ERROR,
RtecEventChannelAdmin::EventChannel::CANT_APPEND_OBSERVER))
{
- return impl_->ftec->append_observer(observer ACE_ENV_ARG_PARAMETER);
+ return impl_->ftec->append_observer(observer);
}
-void FTEC_Gateway::remove_observer (RtecEventChannelAdmin::Observer_Handle handle
- ACE_ENV_ARG_DECL)
+void FTEC_Gateway::remove_observer (RtecEventChannelAdmin::Observer_Handle handle)
ACE_THROW_SPEC ((
CORBA::SystemException,
RtecEventChannelAdmin::EventChannel::SYNCHRONIZATION_ERROR,
RtecEventChannelAdmin::EventChannel::CANT_REMOVE_OBSERVER))
{
- impl_->ftec->remove_observer(handle ACE_ENV_ARG_PARAMETER);
+ impl_->ftec->remove_observer(handle);
}
void FTEC_Gateway::push(RtecEventChannelAdmin::ProxyPushConsumer_ptr proxy_consumer,
- const RtecEventComm::EventSet & data
- ACE_ENV_ARG_DECL)
+ const RtecEventComm::EventSet & data)
{
PortableServer::ObjectId_var object_id =
- impl_->poa->reference_to_id(proxy_consumer ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ impl_->poa->reference_to_id(proxy_consumer);
FtRtecEventComm::ObjectId** result;
memcpy(&result, &object_id[0], sizeof(FtRtecEventComm::ObjectId**));
- impl_->ftec->push(**result, data ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ impl_->ftec->push(**result, data);
}
@@ -315,7 +290,7 @@ FTEC_Gateway_ConsumerAdmin::~FTEC_Gateway_ConsumerAdmin()
}
RtecEventChannelAdmin::ProxyPushSupplier_ptr
-FTEC_Gateway_ConsumerAdmin::obtain_push_supplier (ACE_ENV_SINGLE_ARG_DECL)
+FTEC_Gateway_ConsumerAdmin::obtain_push_supplier (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
@@ -329,7 +304,7 @@ ACE_THROW_SPEC ((CORBA::SystemException))
RtecEventChannelAdmin::ProxyPushSupplier_ptr result;
activate_object_with_id(result, impl_->poa.in(),
&impl_->proxy_supplier_servant,
- local_oid ACE_ENV_ARG_PARAMETER);
+ local_oid);
return result;
}
@@ -346,7 +321,7 @@ FTEC_Gateway_SupplierAdmin::~FTEC_Gateway_SupplierAdmin()
// = The RtecEventChannelAdmin::SupplierAdmin methods...
RtecEventChannelAdmin::ProxyPushConsumer_ptr
-FTEC_Gateway_SupplierAdmin::obtain_push_consumer (ACE_ENV_SINGLE_ARG_DECL)
+FTEC_Gateway_SupplierAdmin::obtain_push_consumer (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
FtRtecEventComm::ObjectId** remote_proxy_oid_ptr;
@@ -359,23 +334,20 @@ ACE_THROW_SPEC ((CORBA::SystemException))
RtecEventChannelAdmin::ProxyPushConsumer_ptr result;
activate_object_with_id(result, impl_->poa.in(),
&impl_->proxy_consumer_servant,
- local_oid ACE_ENV_ARG_PARAMETER);
+ local_oid);
return result;
}
FtRtecEventComm::ObjectId**
-get_remote_oid_ptr(CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
+get_remote_oid_ptr(CORBA::ORB_ptr orb)
{
PortableServer::Current_var current =
resolve_init<PortableServer::Current>(orb,
- "POACurrent"
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ "POACurrent");
PortableServer::ObjectId_var object_id =
- current->get_object_id(ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_CHECK_RETURN(0);
+ current->get_object_id();
FtRtecEventComm::ObjectId** result;
memcpy(&result, &object_id[0], sizeof(FtRtecEventComm::ObjectId**));
@@ -397,47 +369,38 @@ FTEC_Gateway_ProxyPushSupplier::~FTEC_Gateway_ProxyPushSupplier()
// = The RtecEventChannelAdmin::ProxyPushSupplier methods...
void FTEC_Gateway_ProxyPushSupplier::connect_push_consumer (
RtecEventComm::PushConsumer_ptr push_consumer,
- const RtecEventChannelAdmin::ConsumerQOS &qos
- ACE_ENV_ARG_DECL)
+ const RtecEventChannelAdmin::ConsumerQOS &qos)
ACE_THROW_SPEC ((CORBA::SystemException,
RtecEventChannelAdmin::AlreadyConnected,
RtecEventChannelAdmin::TypeError))
{
- FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in());
- *oid_ptr = impl_->ftec->connect_push_consumer(push_consumer, qos ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ *oid_ptr = impl_->ftec->connect_push_consumer(push_consumer, qos);
}
-void FTEC_Gateway_ProxyPushSupplier::disconnect_push_supplier (ACE_ENV_SINGLE_ARG_DECL)
+void FTEC_Gateway_ProxyPushSupplier::disconnect_push_supplier (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
- FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
- impl_->ftec->disconnect_push_supplier(**oid_ptr ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in());
+ impl_->ftec->disconnect_push_supplier(**oid_ptr);
delete *oid_ptr;
delete oid_ptr;
}
-void FTEC_Gateway_ProxyPushSupplier::suspend_connection (ACE_ENV_SINGLE_ARG_DECL)
+void FTEC_Gateway_ProxyPushSupplier::suspend_connection (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
- FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
- impl_->ftec->suspend_push_supplier(**oid_ptr ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in());
+ impl_->ftec->suspend_push_supplier(**oid_ptr);
}
-void FTEC_Gateway_ProxyPushSupplier::resume_connection (ACE_ENV_SINGLE_ARG_DECL)
+void FTEC_Gateway_ProxyPushSupplier::resume_connection (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
- FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
- impl_->ftec->resume_push_supplier(**oid_ptr ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in());
+ impl_->ftec->resume_push_supplier(**oid_ptr);
}
/// FTEC_Gateway_ProxyPushConsumer
@@ -454,47 +417,38 @@ FTEC_Gateway_ProxyPushConsumer::~FTEC_Gateway_ProxyPushConsumer()
// = The RtecEventChannelAdmin::ProxyPushConsumer methods...
-void FTEC_Gateway_ProxyPushConsumer::push (const RtecEventComm::EventSet & data
- ACE_ENV_ARG_DECL)
+void FTEC_Gateway_ProxyPushConsumer::push (const RtecEventComm::EventSet & data)
ACE_THROW_SPEC ((CORBA::SystemException))
{
- FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in());
/*
if (CORBA::is_nil(impl_->push_handler.in())) {
- impl_->push_handler = impl_->push_handler_servant._this(ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_CHECK;
+ impl_->push_handler = impl_->push_handler_servant._this();
}
impl_->ftec->sendc_push (impl_->push_handler.in(),
**oid_ptr,
- data ACE_ENV_ARG_PARAMETER);
+ data);
*/
- impl_->ftec->push(**oid_ptr, data ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ impl_->ftec->push(**oid_ptr, data);
}
void FTEC_Gateway_ProxyPushConsumer::connect_push_supplier (
RtecEventComm::PushSupplier_ptr push_supplier,
- const RtecEventChannelAdmin::SupplierQOS& qos
- ACE_ENV_ARG_DECL)
+ const RtecEventChannelAdmin::SupplierQOS& qos)
ACE_THROW_SPEC ((CORBA::SystemException,
RtecEventChannelAdmin::AlreadyConnected))
{
- FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
- *oid_ptr = impl_->ftec->connect_push_supplier(push_supplier, qos ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in());
+ *oid_ptr = impl_->ftec->connect_push_supplier(push_supplier, qos);
}
-void FTEC_Gateway_ProxyPushConsumer::disconnect_push_consumer (ACE_ENV_SINGLE_ARG_DECL)
+void FTEC_Gateway_ProxyPushConsumer::disconnect_push_consumer (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
- FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in() ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
- impl_->ftec->disconnect_push_consumer(**oid_ptr ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
+ FtRtecEventComm::ObjectId** oid_ptr = get_remote_oid_ptr(impl_->orb.in());
+ impl_->ftec->disconnect_push_consumer(**oid_ptr);
delete *oid_ptr;
delete oid_ptr;
}
@@ -507,13 +461,12 @@ PushConsumerHandler::~PushConsumerHandler()
{
}
-void PushConsumerHandler::push (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+void PushConsumerHandler::push (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
}
-void PushConsumerHandler::push_excep (::Messaging::ExceptionHolder *
- ACE_ENV_ARG_DECL_NOT_USED)
+void PushConsumerHandler::push_excep (::Messaging::ExceptionHolder *)
ACE_THROW_SPEC ((CORBA::SystemException))
{
}