summaryrefslogtreecommitdiff
path: root/TAO/CIAO/ciao/Servant_Impl_Base.h
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/CIAO/ciao/Servant_Impl_Base.h')
-rw-r--r--TAO/CIAO/ciao/Servant_Impl_Base.h116
1 files changed, 41 insertions, 75 deletions
diff --git a/TAO/CIAO/ciao/Servant_Impl_Base.h b/TAO/CIAO/ciao/Servant_Impl_Base.h
index da5603f98d2..4a32b5e8e57 100644
--- a/TAO/CIAO/ciao/Servant_Impl_Base.h
+++ b/TAO/CIAO/ciao/Servant_Impl_Base.h
@@ -19,15 +19,12 @@
#include /**/ "ace/pre.h"
-#include "ace/Array_Map.h"
+#include "ace/Hash_Map_Manager_T.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
-#include "ace/Active_Map_Manager_T.h"
-#include "ace/Thread_Mutex.h"
-
#include "CCM_EventC.h"
#include "CIAO_Server_Export.h"
#include "CCM_ComponentS.h"
@@ -51,7 +48,9 @@ namespace CIAO
: public virtual POA_Components::CCMObject
{
public:
- Servant_Impl_Base (Components::CCMHome_ptr home,
+ explicit Servant_Impl_Base (void);
+
+ Servant_Impl_Base (Components::CCMHome_ptr home,
Home_Servant_Impl_Base *home_servant,
Session_Container * c);
@@ -108,11 +107,11 @@ namespace CIAO
get_all_facets (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException));
-
+
virtual ::Components::ConsumerDescriptions *
get_all_consumers (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException));
-
+
virtual ::Components::EventConsumerBase_ptr
get_consumer (const char *sink_name
@@ -120,6 +119,13 @@ namespace CIAO
ACE_THROW_SPEC ((CORBA::SystemException,
Components::InvalidName));
+ virtual ::Components::EventConsumerBase_ptr
+ disconnect_consumer (const char *source_name
+ ACE_ENV_ARG_DECL_WITH_DEFAULTS)
+ ACE_THROW_SPEC ((CORBA::SystemException,
+ Components::InvalidName,
+ Components::NoConnection));
+
virtual ::Components::ConsumerDescriptions *
get_named_consumers (const ::Components::NameList & names
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
@@ -127,18 +133,30 @@ namespace CIAO
Components::InvalidName));
virtual ::Components::EmitterDescriptions *
- get_named_emitters (const ::Components::NameList & names
+ get_all_emitters (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
+ ACE_THROW_SPEC ((CORBA::SystemException));
+
+ virtual ::Components::EmitterDescriptions *
+ get_named_emitters (const ::Components::NameList & /* names */
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException,
Components::InvalidName));
virtual ::Components::ReceptacleDescriptions *
- get_named_receptacles (const ::Components::NameList & names
+ get_all_receptacles (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
+ ACE_THROW_SPEC ((CORBA::SystemException));
+
+ virtual ::Components::ReceptacleDescriptions *
+ get_named_receptacles (const ::Components::NameList & /* names */
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException,
Components::InvalidName));
virtual ::Components::PublisherDescriptions *
+ get_all_publishers (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
+ ACE_THROW_SPEC ((CORBA::SystemException));
+
+ virtual ::Components::PublisherDescriptions *
get_named_publishers (const ::Components::NameList & names
ACE_ENV_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException,
@@ -149,7 +167,7 @@ namespace CIAO
ACE_ENV_ARG_DECL) = 0;
// Creates and returns the StandardConfigurator for the component.
- virtual ::Components::StandardConfigurator_ptr
+ virtual ::Components::StandardConfigurator_ptr
get_standard_configurator (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
ACE_THROW_SPEC ((CORBA::SystemException));
@@ -162,9 +180,7 @@ namespace CIAO
protected:
void add_facet (const char *port_name,
- ::CORBA::Object_ptr port_ref
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC (( ::CORBA::SystemException));
+ CORBA::Object_ptr port_ref);
CORBA::Object_ptr lookup_facet (const char *port_name);
@@ -173,9 +189,7 @@ namespace CIAO
);
void add_consumer (const char *port_name,
- ::Components::EventConsumerBase_ptr port_ref
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC (( ::CORBA::SystemException));
+ ::Components::EventConsumerBase_ptr port_ref);
::Components::EventConsumerBase_ptr lookup_consumer (
const char *port_name
@@ -184,53 +198,20 @@ namespace CIAO
::Components::ConsumerDescription *lookup_consumer_description (
const char *port_name
);
-
- /// Called from generated servant class to help with
- /// get_all_*() methods.
-
- template<typename T_var>
- static void describe_simplex_receptacle (
- const char *port_name,
- const char *port_type_repo_id,
- T_var &connection,
- ::Components::ReceptacleDescriptions_var &descriptions,
- CORBA::ULong slot
- );
-
- template<typename T_var>
- static void describe_multiplex_receptacle (
- const char *port_name,
- const char *port_type_repo_id,
- ACE_Active_Map_Manager<T_var> &objrefs,
- ::Components::ReceptacleDescriptions_var &descriptions,
- CORBA::ULong slot
- );
-
- template<typename T_var>
- static void describe_pub_event_source (
- const char *port_name,
- const char *port_type_repo_id,
- ACE_Active_Map_Manager<T_var> &consumers,
- ::Components::PublisherDescriptions_var &descriptions,
- CORBA::ULong slot
- );
-
- template<typename T_var>
- static void describe_emit_event_source (
- const char *port_name,
- const char *port_type_repo_id,
- T_var &consumer_ref,
- ::Components::EmitterDescriptions_var &descriptions,
- CORBA::ULong slot
- );
-
+
protected:
- typedef ACE_Array_Map<ACE_CString,
- ::Components::FacetDescription_var>
+ typedef ACE_Hash_Map_Manager_Ex<const char *,
+ ::Components::FacetDescription_var,
+ ACE_Hash<const char *>,
+ ACE_Equal_To<const char *>,
+ ACE_Null_Mutex>
FacetTable;
- typedef ACE_Array_Map<ACE_CString,
- ::Components::ConsumerDescription_var>
+ typedef ACE_Hash_Map_Manager_Ex<const char *,
+ ::Components::ConsumerDescription_var,
+ ACE_Hash<const char *>,
+ ACE_Equal_To<const char *>,
+ ACE_Null_Mutex>
ConsumerTable;
FacetTable facet_table_;
@@ -238,24 +219,9 @@ namespace CIAO
Components::CCMHome_var home_;
Home_Servant_Impl_Base *home_servant_;
Session_Container * container_;
- private:
- /// Not allowed to be used
- Servant_Impl_Base (void);
-
- private:
- /// For internal locking of table reads and writes.
- TAO_SYNCH_MUTEX lock_;
};
}
-#if defined (ACE_TEMPLATES_REQUIRE_SOURCE)
-#include "Servant_Impl_Utils_T.cpp"
-#endif /* ACE_TEMPLATES_REQUIRE_SOURCE */
-
-#if defined (ACE_TEMPLATES_REQUIRE_PRAGMA)
-#pragma implementation ("Servant_Impl_Utils_T.cpp")
-#endif /* ACE_TEMPLATES_REQUIRE_PRAGMA */
-
#include /**/ "ace/post.h"
#endif /* CIAO_SERVANT_IMPL_T_H */