diff options
Diffstat (limited to 'TAO/tests/Exposed_Policies/Policy_Tester.cpp')
-rw-r--r-- | TAO/tests/Exposed_Policies/Policy_Tester.cpp | 70 |
1 files changed, 35 insertions, 35 deletions
diff --git a/TAO/tests/Exposed_Policies/Policy_Tester.cpp b/TAO/tests/Exposed_Policies/Policy_Tester.cpp index 841d29cd783..e8beea4ce17 100644 --- a/TAO/tests/Exposed_Policies/Policy_Tester.cpp +++ b/TAO/tests/Exposed_Policies/Policy_Tester.cpp @@ -28,38 +28,38 @@ Policy_Tester::~Policy_Tester (void) } void -Policy_Tester::run (CORBA::Environment &ACE_TRY_ENV) +Policy_Tester::run (TAO_ENV_SINGLE_ARG_DECL) { PortableServer::POAManager_var poa_manager = - this->child_poa_->the_POAManager (ACE_TRY_ENV); + this->child_poa_->the_POAManager (TAO_ENV_SINGLE_ARG_PARAMETER); ACE_CHECK; - poa_manager->activate (ACE_TRY_ENV); + poa_manager->activate (TAO_ENV_SINGLE_ARG_PARAMETER); ACE_CHECK; - this->orb_->run (ACE_TRY_ENV); + this->orb_->run (TAO_ENV_SINGLE_ARG_PARAMETER); ACE_CHECK; } int Policy_Tester::init (int argc, - char *argv[], - CORBA::Environment &ACE_TRY_ENV) + char *argv[] + TAO_ENV_ARG_DECL) { // ORB Initialization. this->orb_ = - CORBA::ORB_init (argc, argv, "", - ACE_TRY_ENV); + CORBA::ORB_init (argc, argv, "" + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); // Get a reference to the RT-ORB. CORBA::Object_var object = - this->orb_->resolve_initial_references ("RTORB", - ACE_TRY_ENV); + this->orb_->resolve_initial_references ("RTORB" + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); - this->rt_orb_ = RTCORBA::RTORB::_narrow (object.in (), - ACE_TRY_ENV); + this->rt_orb_ = RTCORBA::RTORB::_narrow (object.in () + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); // Here we parse the command line paramether passed @@ -74,13 +74,13 @@ Policy_Tester::init (int argc, if ((arg = arg_shifter.get_the_parameter ("-POAConfigFile"))) { this->rt_poa_properties_ = - RT_Properties::read_from (arg, ACE_TRY_ENV); + RT_Properties::read_from (arg TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); } else if ((arg = arg_shifter.get_the_parameter ("-ObjectConfigFile"))) { this->rt_object_properties_ = - RT_Properties::read_from (arg, ACE_TRY_ENV); + RT_Properties::read_from (arg TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); } else if ((arg = arg_shifter.get_the_parameter ("-BaseObjectIOR"))) @@ -119,7 +119,7 @@ Policy_Tester::init (int argc, } int result = - this->create_objects (ACE_TRY_ENV); + this->create_objects (TAO_ENV_SINGLE_ARG_PARAMETER); ACE_CHECK_RETURN (-1); if (result != 0) @@ -142,7 +142,7 @@ Policy_Tester::check_reference (CORBA::Object_ptr object, int -Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) +Policy_Tester::create_objects (TAO_ENV_SINGLE_ARG_DECL) { CORBA::PolicyList poa_policy_list; poa_policy_list.length (3); @@ -151,8 +151,8 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) RTCORBA::Priority priority = this->rt_poa_properties_->priority (); poa_policy_list[0] = this->rt_orb_->create_priority_model_policy (RTCORBA::SERVER_DECLARED, - priority, - ACE_TRY_ENV); + priority + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); // Create priority Banded Connection Policy. @@ -160,8 +160,8 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) this->rt_poa_properties_->priority_bands (); poa_policy_list[1] = - this->rt_orb_->create_priority_banded_connection_policy (poa_priority_bands, - ACE_TRY_ENV); + this->rt_orb_->create_priority_banded_connection_policy (poa_priority_bands + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); // Client Protocol Policy. @@ -179,11 +179,11 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) this->rt_orb_->create_client_protocol_policy (protocol_list); CORBA::Object_var object = - this->orb_->resolve_initial_references ("RootPOA", ACE_TRY_ENV); + this->orb_->resolve_initial_references ("RootPOA" TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); this->poa_ = - PortableServer::POA::_narrow (object.in (), ACE_TRY_ENV); + PortableServer::POA::_narrow (object.in () TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); PortableServer::POAManager_var poa_mgr = @@ -192,19 +192,19 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) object = this->poa_->create_POA ("Child_POA", poa_mgr.in (), - poa_policy_list, - ACE_TRY_ENV); + poa_policy_list + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); this->child_poa_ = - RTPortableServer::POA::_narrow (object.in (), ACE_TRY_ENV); + RTPortableServer::POA::_narrow (object.in () TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); // Create a Corba Object reference, using the policies // set at the POA level. object = - this->child_poa_->create_reference ("IDL:Counter:1.0", - ACE_TRY_ENV); + this->child_poa_->create_reference ("IDL:Counter:1.0" + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); ACE_DEBUG ((LM_DEBUG, @@ -214,7 +214,7 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) "Unable to create Object!\n")) return -1; - Counter_var base_object = Counter::_narrow (object.in (), ACE_TRY_ENV); + Counter_var base_object = Counter::_narrow (object.in () TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); if (!check_reference (base_object.in(), @@ -222,7 +222,7 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) return -1; CORBA::String_var ior = - this->orb_->object_to_string (base_object.in (), ACE_TRY_ENV); + this->orb_->object_to_string (base_object.in () TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); ACE_DEBUG ((LM_DEBUG, @@ -247,8 +247,8 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) object = this->child_poa_->create_reference_with_priority ("IDL:Counter:1.0", - this->rt_object_properties_->priority (), - ACE_TRY_ENV); + this->rt_object_properties_->priority () + TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); ACE_DEBUG ((LM_DEBUG, @@ -258,7 +258,7 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) "Unable to create a Counter Object!\n")) return -1; - Counter_var over_object = Counter::_narrow (object.in (), ACE_TRY_ENV); + Counter_var over_object = Counter::_narrow (object.in () TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); if (!check_reference (over_object.in(), @@ -267,7 +267,7 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) CORBA::String_var o_ior = - this->orb_->object_to_string (over_object.in (), ACE_TRY_ENV); + this->orb_->object_to_string (over_object.in () TAO_ENV_ARG_PARAMETER); ACE_CHECK_RETURN (-1); ACE_DEBUG ((LM_DEBUG, @@ -286,8 +286,8 @@ Policy_Tester::create_objects (CORBA::Environment &ACE_TRY_ENV) } void -Policy_Tester::shutdown (CORBA::Environment &ACE_TRY_ENV) +Policy_Tester::shutdown (TAO_ENV_SINGLE_ARG_DECL) { - this->orb_->shutdown (0, ACE_TRY_ENV); + this->orb_->shutdown (0 TAO_ENV_ARG_PARAMETER); ACE_CHECK; } |