#include <Container_Impl.h>
Collaboration diagram for CIAO::Container_Impl:
Public Member Functions | |
Container_Impl (CORBA::ORB_ptr o, PortableServer::POA_ptr p,::Deployment::NodeApplication_ptr server, NodeApp_Configurator &c, const Static_Config_EntryPoints_Maps *static_entrypts_maps=0) | |
Constructor. | |
virtual | ~Container_Impl (void) |
Destructor. | |
virtual CORBA::Long | init (const CORBA::PolicyList *policies) |
Initialize the container. | |
Deployment::ComponentInfos * | install (const ::Deployment::ContainerImplementationInfo &container_impl_info) |
Install all homes and components. | |
virtual void | remove () |
Remove all homes and components. | |
virtual ::Deployment::Properties * | properties () |
Deployment::Container interface defined attributes/operations. | |
virtual ::Deployment::NodeApplication_ptr | get_node_application () |
virtual PortableServer::POA_ptr | _default_POA (void) |
virtual ::Components::CCMHome_ptr | install_home (const ::Deployment::ComponentImplementationInfo &impl_info) |
virtual void | remove_home (const char *comp_ins_name) |
bool | register_with_ns (const char *obj_name, CORBA::ORB_ptr orb, Components::CCMObject_ptr obj) |
bool | unregister_with_ns (const char *obj_name, CORBA::ORB_ptr orb) |
virtual void | remove_components () |
virtual void | remove_component (const char *comp_ins_name) |
void | set_objref (Deployment::Container_ptr o) |
Set the cached object reference. | |
Deployment::Container_ptr | get_objref () |
Protected Types | |
typedef ACE_Hash_Map_Manager_Ex< ACE_CString, Components::CCMHome_ptr, ACE_Hash< ACE_CString >, ACE_Equal_To< ACE_CString >, ACE_Null_Mutex > | CCMHome_Map |
To store all created CCMHome object. | |
typedef CCMHome_Map::iterator | Home_Iterator |
typedef ACE_Hash_Map_Manager_Ex< ACE_CString, Components::CCMObject_var, ACE_Hash< ACE_CString >, ACE_Equal_To< ACE_CString >, ACE_Null_Mutex > | CCMComponent_Map |
To store all created Component object. | |
typedef CCMComponent_Map::iterator | Component_Iterator |
typedef ACE_Hash_Map_Manager_Ex< ACE_CString, ACE_CString, ACE_Hash< ACE_CString >, ACE_Equal_To< ACE_CString >, ACE_Null_Mutex > | CCMNaming_Map |
Protected Attributes | |
CORBA::ORB_var | orb_ |
Keep a pointer to the managing ORB serving this servant. | |
PortableServer::POA_var | poa_ |
Keep a pointer to the managing POA. | |
CIAO::Container * | container_ |
Internal container implementation. | |
Deployment::Properties | properties_ |
Cached ConfigValues. | |
Deployment::Container_var | objref_ |
Cached Container reference (of ourselves.). | |
Deployment::NodeApplication_var | nodeapp_ |
Cached NodeApplication. | |
NodeApp_Configurator & | configurator_ |
CCMHome_Map | home_map_ |
CCMComponent_Map | component_map_ |
CCMNaming_Map | naming_map_ |
const Static_Config_EntryPoints_Maps * | static_entrypts_maps_ |
This class implements the Deployment::Container interface which is not defined by the CCM DnC specification. As the interface implies, this is actually part of the deployment interface and is used to manage the lifecycle of the installed components and homes.
typedef ACE_Hash_Map_Manager_Ex<ACE_CString, Components::CCMObject_var, ACE_Hash<ACE_CString>, ACE_Equal_To<ACE_CString>, ACE_Null_Mutex> CIAO::Container_Impl::CCMComponent_Map [protected] |
To store all created Component object.
typedef ACE_Hash_Map_Manager_Ex<ACE_CString, Components::CCMHome_ptr, ACE_Hash<ACE_CString>, ACE_Equal_To<ACE_CString>, ACE_Null_Mutex> CIAO::Container_Impl::CCMHome_Map [protected] |
To store all created CCMHome object.
typedef ACE_Hash_Map_Manager_Ex<ACE_CString, ACE_CString, ACE_Hash<ACE_CString>, ACE_Equal_To<ACE_CString>, ACE_Null_Mutex> CIAO::Container_Impl::CCMNaming_Map [protected] |
typedef CCMComponent_Map::iterator CIAO::Container_Impl::Component_Iterator [protected] |
typedef CCMHome_Map::iterator CIAO::Container_Impl::Home_Iterator [protected] |
ACE_INLINE CIAO::Container_Impl::Container_Impl | ( | CORBA::ORB_ptr | o, | |
PortableServer::POA_ptr | p, | |||
::Deployment::NodeApplication_ptr | server, | |||
NodeApp_Configurator & | c, | |||
const Static_Config_EntryPoints_Maps * | static_entrypts_maps = 0 | |||
) |
Constructor.
CIAO::Container_Impl::~Container_Impl | ( | void | ) | [virtual] |
Destructor.
PortableServer::POA_ptr CIAO::Container_Impl::_default_POA | ( | void | ) | [virtual] |
Get the containing POA. This operation does *not* increase the reference count of the POA.
Deployment::NodeApplication_ptr CIAO::Container_Impl::get_node_application | ( | ) |
ACE_INLINE::Deployment::Container_ptr CIAO::Container_Impl::get_objref | ( | ) |
Get the cached object reference. This operation will invoke _this if there's no cached reference available. Notice that this method does *NOT* increase the reference count of the cached reference. @ Gan, caller should own memory. In this case you shoudl return a duplicate OR add a const to the operation signature. This is simply bad programming.
CORBA::Long CIAO::Container_Impl::init | ( | const CORBA::PolicyList * | policies | ) | [virtual] |
Initialize the container.
Deployment::ComponentInfos * CIAO::Container_Impl::install | ( | const ::Deployment::ContainerImplementationInfo & | container_impl_info | ) |
Install all homes and components.
Components::CCMHome_ptr CIAO::Container_Impl::install_home | ( | const ::Deployment::ComponentImplementationInfo & | impl_info | ) |
Deployment::Properties * CIAO::Container_Impl::properties | ( | ) |
Deployment::Container interface defined attributes/operations.
bool CIAO::Container_Impl::register_with_ns | ( | const char * | obj_name, | |
CORBA::ORB_ptr | orb, | |||
Components::CCMObject_ptr | obj | |||
) |
void CIAO::Container_Impl::remove | ( | ) | [virtual] |
Remove all homes and components.
void CIAO::Container_Impl::remove_component | ( | const char * | comp_ins_name | ) | [virtual] |
void CIAO::Container_Impl::remove_components | ( | ) | [virtual] |
void CIAO::Container_Impl::remove_home | ( | const char * | comp_ins_name | ) | [virtual] |
@Note: I don't know how to remove a home right now. I assume that user will only call remove instead. This is true at least for DnC run time.
Right now, in this implementation I assumpe that there will be same number of homes as the components even if the components are of the same type. I don't think that we have the modeling side support of this either. So bear me if you think I avoid the real thinking for easiness.
ACE_INLINE void CIAO::Container_Impl::set_objref | ( | Deployment::Container_ptr | o | ) |
Set the cached object reference.
bool CIAO::Container_Impl::unregister_with_ns | ( | const char * | obj_name, | |
CORBA::ORB_ptr | orb | |||
) |
CCMComponent_Map CIAO::Container_Impl::component_map_ [protected] |
NodeApp_Configurator& CIAO::Container_Impl::configurator_ [protected] |
CIAO::Container* CIAO::Container_Impl::container_ [protected] |
Internal container implementation.
CCMHome_Map CIAO::Container_Impl::home_map_ [protected] |
CCMNaming_Map CIAO::Container_Impl::naming_map_ [protected] |
Deployment::NodeApplication_var CIAO::Container_Impl::nodeapp_ [protected] |
Cached NodeApplication.
Deployment::Container_var CIAO::Container_Impl::objref_ [protected] |
Cached Container reference (of ourselves.).
CORBA::ORB_var CIAO::Container_Impl::orb_ [protected] |
Keep a pointer to the managing ORB serving this servant.
PortableServer::POA_var CIAO::Container_Impl::poa_ [protected] |
Keep a pointer to the managing POA.
Cached ConfigValues.
const Static_Config_EntryPoints_Maps* CIAO::Container_Impl::static_entrypts_maps_ [protected] |