summaryrefslogtreecommitdiff
path: root/TAO/CIAO/DAnCE/ciao/Container_Base.h
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/CIAO/DAnCE/ciao/Container_Base.h')
-rw-r--r--TAO/CIAO/DAnCE/ciao/Container_Base.h101
1 files changed, 21 insertions, 80 deletions
diff --git a/TAO/CIAO/DAnCE/ciao/Container_Base.h b/TAO/CIAO/DAnCE/ciao/Container_Base.h
index b76cf9da544..2a618114c7d 100644
--- a/TAO/CIAO/DAnCE/ciao/Container_Base.h
+++ b/TAO/CIAO/DAnCE/ciao/Container_Base.h
@@ -20,9 +20,9 @@
#include "tao/ORB.h"
#include "tao/PortableServer/PortableServer.h"
#include "tao/PortableServer/Servant_Base.h"
-#include "ciao/CCM_ContainerC.h"
-#include "ciao/Deployment_CoreC.h"
-#include "ciao/CIAO_Server_Export.h"
+#include "CCM_ContainerC.h"
+#include "Deployment_CoreC.h"
+#include "CIAO_Server_Export.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
@@ -30,8 +30,6 @@
namespace CIAO
{
- class Servant_Activator;
-
/**
* @class Container
*
@@ -43,25 +41,16 @@ namespace CIAO
class CIAO_SERVER_Export Container
{
public:
- enum OA_Type
- {
- Component,
- Facet_Consumer
- };
-
Container (CORBA::ORB_ptr o);
virtual ~Container (void) = 0;
- /// Get component's POA.
- /**
- * This operation does *NOT* increase the reference count of the
- * POA. Look at the const qualifier in the method.
- */
- PortableServer::POA_ptr the_POA (void) const;
+ /// Get the containing POA. This operation does *NOT*
+ /// increase the reference count of the POA.
+ virtual PortableServer::POA_ptr _ciao_the_POA (void);
/// Get a reference to the underlying ORB.
- CORBA::ORB_ptr the_ORB (void) const;
+ virtual CORBA::ORB_ptr _ciao_the_ORB (void);
/// Initialize the container with a name.
virtual int init (const char *name = 0,
@@ -88,25 +77,14 @@ namespace CIAO
// Uninstall a servant for component.
virtual void uninstall_component (::Components::CCMObject_ptr objref,
- PortableServer::ObjectId_out oid
- ACE_ENV_ARG_DECL_WITH_DEFAULTS)
+ PortableServer::ObjectId_out oid
+ ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException)) = 0;
-
protected:
CORBA::ORB_var orb_;
- /// POA within which all the components in this container will be
- /// activated.
- PortableServer::POA_var component_poa_;
-
- /// POA within which all the facets and receptacles will be
- /// activated.
- /**
- * Having two POA's allows us to associate different policies that
- * are distinct from the component.
- */
- PortableServer::POA_var facet_cons_poa_;
+ PortableServer::POA_var poa_;
};
class Session_Container;
@@ -115,10 +93,7 @@ namespace CIAO
typedef ::PortableServer::Servant (*ServantFactory)
(::Components::HomeExecutorBase_ptr p,
::CIAO::Session_Container *c
-#if !defined (TAO_HAS_EXCEPTIONS) || defined (ACE_ENV_BKWD_COMPAT)
- , CORBA::Environment &
-#endif
- );
+ ACE_ENV_ARG_DECL_WITH_DEFAULTS);
typedef ACE_Hash_Map_Manager_Ex<ACE_CString,
HomeFactory,
@@ -149,8 +124,9 @@ namespace CIAO
// It appears to be a boolean value. Please use bool
// instead.
Session_Container (CORBA::ORB_ptr o,
- bool static_config_flag = false,
- const Static_Config_EntryPoints_Maps* static_entrypts_maps =0);
+ int static_config_flag =0,
+ const Static_Config_EntryPoints_Maps* static_entrypts_maps =0
+ );
virtual ~Session_Container (void);
@@ -158,7 +134,6 @@ namespace CIAO
virtual int init (const char *name = 0,
const CORBA::PolicyList *more_policies = 0
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
-
ACE_THROW_SPEC ((CORBA::SystemException));
/**
@@ -190,13 +165,12 @@ namespace CIAO
// Uninstall a servant for component.
virtual void uninstall_component (::Components::CCMObject_ptr objref,
- PortableServer::ObjectId_out oid
- ACE_ENV_ARG_DECL_WITH_DEFAULTS)
+ PortableServer::ObjectId_out oid
+ ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException));
// Install a servant for component or home.
- CORBA::Object_ptr install_servant (PortableServer::Servant p,
- Container::OA_Type t
+ CORBA::Object_ptr install_servant (PortableServer::Servant p
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException));
@@ -212,44 +186,15 @@ namespace CIAO
ACE_THROW_SPEC ((CORBA::SystemException));
// Uninstall a servant for component or home.
- void uninstall (CORBA::Object_ptr objref,
- Container::OA_Type t
+ void uninstall (CORBA::Object_ptr objref
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException));
// Uninstall a servant for component or home.
- void uninstall (PortableServer::Servant svt,
- Container::OA_Type t
+ void uninstall (PortableServer::Servant svt
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException));
- // Analog of the POA method that creates an object reference from
- // an object id string.
- CORBA::Object_ptr generate_reference (const char *obj_id,
- const char *repo_id,
- Container::OA_Type t
- ACE_ENV_ARG_DECL);
-
- /// Return the servant activator factory that activates the
- /// servants for facets and consumers.
- Servant_Activator *ports_servant_activator (void) const;
-
- private:
-
- /// Create POA for the component.
- /**
- * This is the POA that is returned to the component applications
- * if they need one.
- */
- void create_component_POA (const char *name,
- const CORBA::PolicyList *p,
- PortableServer::POA_ptr root
- ACE_ENV_ARG_DECL);
-
- /// Create POA for the facets and consumers alone.
- void create_facet_consumer_POA (PortableServer::POA_ptr root
- ACE_ENV_ARG_DECL);
-
protected:
long number_;
@@ -259,12 +204,8 @@ namespace CIAO
// boolean value. Please use bool instead.
//
// It looks like it can also be declared const, as well.
- bool static_config_flag_;
+ int static_config_flag_;
const Static_Config_EntryPoints_Maps* static_entrypts_maps_;
-
- /// The servant activator factory used to activate facets and
- /// consumer servants.
- Servant_Activator *sa_;
};
}
@@ -277,7 +218,7 @@ namespace CIAO
{ \
CORBA::ValueFactory factory = new FACTORY; \
CORBA::ORB_ptr orb = \
- this->context_->_ciao_the_Container ()->the_ORB (); \
+ this->context_->_ciao_the_Container ()->_ciao_the_ORB (); \
CORBA::ValueFactory prev_factory = \
orb->register_value_factory ( \
VALUETYPE::_tao_obv_static_repository_id (), \