summaryrefslogtreecommitdiff
path: root/TAO/CIAO/examples/Hello/Sender/New_Sender_svnt.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/CIAO/examples/Hello/Sender/New_Sender_svnt.cpp')
-rw-r--r--TAO/CIAO/examples/Hello/Sender/New_Sender_svnt.cpp352
1 files changed, 0 insertions, 352 deletions
diff --git a/TAO/CIAO/examples/Hello/Sender/New_Sender_svnt.cpp b/TAO/CIAO/examples/Hello/Sender/New_Sender_svnt.cpp
deleted file mode 100644
index aa2c2b8081c..00000000000
--- a/TAO/CIAO/examples/Hello/Sender/New_Sender_svnt.cpp
+++ /dev/null
@@ -1,352 +0,0 @@
-// $Id$
-//
-// **** Code generated by the ****
-// **** Component Integrated ACE ORB (CIAO) CIDL Compiler ****
-// CIAO has been developed by:
-// Center for Distributed Object Computing
-// Washington University
-// St. Louis, MO
-// USA
-// http://www.cs.wustl.edu/~schmidt/doc-center.html
-// CIDL Compiler has been developed by:
-// Institute for Software Integrated Systems
-// Vanderbilt University
-// Nashville, TN
-// USA
-// http://www.isis.vanderbilt.edu/
-//
-// Information about CIAO is available at:
-// http://www.dre.vanderbilt.edu/CIAO
-
-#include "Sender_svnt.h"
-#include "Cookies.h"
-#include "ciao/Servant_Activator.h"
-#include "ciao/Port_Activator_T.h"
-
-namespace Sender_Impl
-{
- namespace CIAO_GLUE_Hello
- {
- Sender_Context::Sender_Context (
- ::Components::CCMHome_ptr home,
- ::CIAO::Swapping_Container *c,
- Sender_Servant *sv)
- : Context_Impl_Base (home, c),
- ctx_svnt_base (home, c, sv)
- {
- }
-
- Sender_Context::~Sender_Context (void)
- {
- }
-
- // Operations for Sender receptacles and event sources,
- // defined in ::Hello::CCM_Sender_Context.
-
- // CIAO-specific.
-
- Sender_Context *
- Sender_Context::_narrow (
- ::Components::SessionContext_ptr p
- ACE_ENV_ARG_DECL_NOT_USED)
- {
- return dynamic_cast<Sender_Context *> (p);
- }
- }
-
- namespace CIAO_GLUE_Hello
- {
- Sender_Servant::Sender_Servant (
- ::Hello::CCM_Sender_ptr exe,
- ::Components::CCMHome_ptr h,
- ::CIAO::Swapping_Container *c)
- : Servant_Impl_Base (c),
- comp_svnt_base (exe, c)
- {
- this->context_ = new Sender_Context (h, c, this);
-
- ACE_TRY_NEW_ENV
- {
- ::Components::SessionComponent_var scom =
- ::Components::SessionComponent::_narrow (
- exe
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (! ::CORBA::is_nil (scom.in ()))
- {
- scom->set_session_context (
- this->context_
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
-
- this->populate_port_tables (
- ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
-
- ACE_CATCHANY
- {
- }
-
- ACE_ENDTRY;
- }
-
- Sender_Servant::~Sender_Servant (void)
- {
- }
-
- void
- Sender_Servant::set_attributes (
- const ::Components::ConfigValues &descr
- ACE_ENV_ARG_DECL_NOT_USED)
- {
- for (CORBA::ULong i = 0;
- i < descr.length ();
- ++i)
- {
- const char *descr_name = descr[i]->name ();
- ::CORBA::Any &descr_value = descr[i]->value ();
-
- if (ACE_OS::strcmp (descr_name, "local_message") == 0)
- {
- const char * _ciao_extract_val = 0;
- descr_value >>= _ciao_extract_val;
- this->local_message (_ciao_extract_val);
- continue;
- }
-
- ACE_UNUSED_ARG (descr_name);
- ACE_UNUSED_ARG (descr_value);
- }
- }
-
- ::Components::Cookie *
- Sender_Servant::connect (
- const char *name,
- ::CORBA::Object_ptr connection
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((
- ::CORBA::SystemException,
- ::Components::InvalidName,
- ::Components::InvalidConnection,
- ::Components::AlreadyConnected,
- ::Components::ExceededConnectionLimit))
- {
- // If the component has no receptacles, this will be unused.
- ACE_UNUSED_ARG (connection);
-
- if (name == 0)
- {
- ACE_THROW_RETURN (::Components::InvalidName (), 0);
- }
-
- ACE_THROW_RETURN (::Components::InvalidName (), 0);
- }
-
- CORBA::Object_ptr
- Sender_Servant::disconnect (
- const char *name,
- ::Components::Cookie * ck
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((
- ::CORBA::SystemException,
- ::Components::InvalidName,
- ::Components::InvalidConnection,
- ::Components::CookieRequired,
- ::Components::NoConnection))
- {
- if (name == 0)
- {
- ACE_THROW_RETURN (
- ::Components::InvalidName (),
- ::CORBA::Object::_nil ());
- }
-
- ACE_THROW_RETURN (
- ::Components::InvalidName (),
- ::CORBA::Object::_nil ());
-
- ACE_UNUSED_ARG (ck);
- }
-
- void
- Sender_Servant::connect_consumer (
- const char * emitter_name,
- ::Components::EventConsumerBase_ptr consumer
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((
- ::CORBA::SystemException,
- ::Components::InvalidName,
- ::Components::AlreadyConnected,
- ::Components::InvalidConnection))
- {
- if (emitter_name == 0)
- {
- ACE_THROW (::CORBA::BAD_PARAM ());
- }
-
- ACE_UNUSED_ARG (consumer);
- ACE_THROW (::Components::InvalidName ());
- }
-
- ::Components::Cookie *
- Sender_Servant::subscribe (
- const char *publisher_name,
- ::Components::EventConsumerBase_ptr subscribe
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((
- ::CORBA::SystemException,
- ::Components::InvalidName,
- ::Components::InvalidConnection,
- ::Components::ExceededConnectionLimit))
- {
- // Just in case there are no if blocks
- ACE_UNUSED_ARG (subscribe);
-
- if (publisher_name == 0)
- {
- ACE_THROW_RETURN (::Components::InvalidName (), 0);
- }
-
- ACE_THROW_RETURN (::Components::InvalidName (), 0);
- }
-
- ::Components::EventConsumerBase_ptr
- Sender_Servant::unsubscribe (
- const char *publisher_name,
- ::Components::Cookie *ck
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((
- ::CORBA::SystemException,
- ::Components::InvalidName,
- ::Components::InvalidConnection))
- {
- // Just in case there are no if blocks
- ACE_UNUSED_ARG (ck);
-
- if (publisher_name == 0)
- {
- ACE_THROW_RETURN (
- ::Components::InvalidName (),
- ::Components::EventConsumerBase::_nil ());
- }
-
- ACE_THROW_RETURN (
- ::Components::InvalidName (),
- ::Components::EventConsumerBase::_nil ());
- }
-
- CORBA::Object_ptr
- Sender_Servant::get_facet_executor (const char *name
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((
- ::CORBA::SystemException))
- {
- if (name == 0)
- {
- ACE_THROW_RETURN (
- ::CORBA::BAD_PARAM (),
- ::CORBA::Object::_nil ());
- }
-
- return CORBA::Object::_nil ();
- }
-
- // Supported operations.
-
- void
- Sender_Servant::start (
- ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
- {
- this->executor_->start (
- ACE_ENV_SINGLE_ARG_PARAMETER);
- }
-
- // Component attribute operations.
-
- char *
- Sender_Servant::local_message (
- ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
- {
- return this->executor_->local_message (
- ACE_ENV_SINGLE_ARG_PARAMETER);
- }
-
- void
- Sender_Servant::local_message (
- const char * local_message
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
- {
- this->executor_->local_message (
- local_message
- ACE_ENV_ARG_PARAMETER);
- }
-
- // Private method to populate the port tables.
- void
- Sender_Servant::populate_port_tables (
- ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
- {
- ::CORBA::Object_var obj_var;
- ::Components::EventConsumerBase_var ecb_var;
- }
- }
-
- namespace CIAO_GLUE_Hello
- {
- SenderHome_Servant::SenderHome_Servant (
- ::Hello::CCM_SenderHome_ptr exe,
- ::CIAO::Swapping_Container *c)
- : Swapping_Servant_Impl_Base (c),
- home_svnt_base (exe, c)
- {
- }
-
- SenderHome_Servant::~SenderHome_Servant (void)
- {
- }
-
- // Home operations.
-
- // Home supported interface operations.
-
- // Home factory and finder operations.
-
- // Home attribute operations.
- }
-
- extern "C" SENDER_SVNT_Export ::PortableServer::Servant
- createSenderHome_Servant (
- ::Components::HomeExecutorBase_ptr p,
- CIAO::Swapping_Container *c
- ACE_ENV_ARG_DECL)
- {
- if (p == 0)
- {
- return 0;
- }
-
- ::Hello::CCM_SenderHome_var x =
- ::Hello::CCM_SenderHome::_narrow (
- p
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (0);
-
- if (::CORBA::is_nil (x.in ()))
- {
- return 0;
- }
-
- return new
- CIAO_GLUE_Hello::SenderHome_Servant (
- x.in (),
- c);
- }
-}
-