Regular_POA.cpp

Go to the documentation of this file.
00001 #include "tao/PortableServer/Regular_POA.h"
00002 
00003 ACE_RCSID (PortableServer,
00004            POA,
00005            "Regular_POA.cpp,v 1.5 2006/04/26 13:22:59 mesnier_p Exp")
00006 
00007 //
00008 #if !defined (__ACE_INLINE__)
00009 # include "tao/PortableServer/Regular_POA.inl"
00010 #endif /* ! __ACE_INLINE__ */
00011 
00012 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00013 
00014 TAO_Regular_POA::TAO_Regular_POA (const TAO_Root_POA::String &name,
00015                                   PortableServer::POAManager_ptr poa_manager,
00016                   const TAO_POA_Policy_Set &policies,
00017                   TAO_Root_POA *parent,
00018                   ACE_Lock &lock,
00019                   TAO_SYNCH_MUTEX &thread_lock,
00020                   TAO_ORB_Core &orb_core,
00021                   TAO_Object_Adapter *object_adapter
00022                   ACE_ENV_ARG_DECL)
00023   : TAO_Root_POA (name,
00024                   poa_manager,
00025                   policies,
00026                   parent,
00027                   lock,
00028                   thread_lock,
00029                   orb_core,
00030                   object_adapter
00031                   ACE_ENV_ARG_PARAMETER),
00032      parent_ (parent)
00033 {
00034 }
00035 
00036 TAO_Regular_POA::~TAO_Regular_POA (void)
00037 {
00038 }
00039 
00040 void
00041 TAO_Regular_POA::remove_from_parent_i (ACE_ENV_SINGLE_ARG_DECL)
00042 {
00043   // Remove POA from the parent
00044   if (this->parent_ != 0)
00045     {
00046       int result = this->parent_->delete_child (this->name_);
00047       if (result != 0)
00048         {
00049           ACE_THROW (CORBA::OBJ_ADAPTER ());
00050         }
00051     }
00052 }
00053 
00054 CORBA::Boolean
00055 TAO_Regular_POA::root (void) const
00056 {
00057   return (parent_ == 0);
00058 }
00059 
00060 char
00061 TAO_Regular_POA::root_key_type (void)
00062 {
00063   if (this->parent_ != 0)
00064     {
00065       return TAO_Root_POA::non_root_key_char ();
00066     }
00067   else
00068     {
00069       return TAO_Root_POA::root_key_type ();
00070     }
00071 }
00072 
00073 TAO_END_VERSIONED_NAMESPACE_DECL

Generated on Thu Nov 9 12:40:40 2006 for TAO_PortableServer by doxygen 1.3.6