Changes to attempt to silence bcc64x
[ACE_TAO.git] / TAO / orbsvcs / tests / FT_Naming / stress_storable / Basic.cpp
blobd96026330f0a8f4f47c2bd838bb3fabefc7b78cf
1 #include "Basic.h"
2 #include "LB_server.h"
3 #include "orbsvcs/PortableGroup/PG_Property_Set.h"
5 Basic::Basic (CORBA::Object_ptr object_group,
6 FT_Naming::NamingManager_ptr lm,
7 CORBA::ORB_ptr orb,
8 const char *loc)
9 : object_group_name_ ("Basic Group"), orb_ (CORBA::ORB::_duplicate (orb))
11 this->object_group_ = CORBA::Object::_duplicate (object_group);
12 this->nm_ = FT_Naming::NamingManager::_duplicate (lm);
13 this->location_ = CORBA::string_dup (loc);
16 char *
17 Basic::get_string ()
19 return CORBA::string_dup (this->location_.in ());
22 void
23 Basic::remove_member ()
25 try
27 PortableGroup::Location location (1);
28 location.length (1);
29 location[0].id = CORBA::string_dup (this->location_.in ());
30 this->object_group_ =
31 this->nm_->remove_member (this->object_group_.in (),
32 location);
34 ACE_DEBUG ((LM_DEBUG, "(%P|%t) - Removed Member at Location <%C>\n",
35 this->location_.in ()));
37 catch (const PortableGroup::ObjectNotFound& ex)
39 ex._tao_print_exception ("Caught exception in remove_member");
40 throw CORBA::INTERNAL ();
42 catch (const PortableGroup::MemberNotFound& ex)
44 ex._tao_print_exception ("Caught exception in remove_member");
45 throw CORBA::INTERNAL ();
47 catch (const CORBA::Exception& ex)
49 ex._tao_print_exception ("Exception caught while destroying member\n");
55 void
56 Basic::shutdown ()
58 this->orb_->shutdown (false);