Exemplo n.º 1
0
TAO_Stub *
TAO_Default_Stub_Factory::create_stub (const char *repository_id,
                                       const TAO_MProfile &profiles,
                                       TAO_ORB_Core *orb_core)
{
  TAO_Stub *retval = 0;

  ACE_NEW_THROW_EX (retval,
                    TAO_Stub (repository_id, profiles, orb_core),
                    CORBA::NO_MEMORY (0,
                                      CORBA::COMPLETED_MAYBE));

  return retval;
}

// ****************************************************************

ACE_STATIC_SVC_DEFINE (
    TAO_Default_Stub_Factory,
    ACE_TEXT ("Default_Stub_Factory"),
    ACE_SVC_OBJ_T,
    &ACE_SVC_NAME (TAO_Default_Stub_Factory),
    ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
    0
  )
ACE_FACTORY_DEFINE (TAO, TAO_Default_Stub_Factory)

TAO_END_VERSIONED_NAMESPACE_DECL

Exemplo n.º 2
0
    return r;
  }

  int  Replication_Service::release (void)
  {
    int r= replication_strategy->release();
    TAO_FTRTEC::Log(3, ACE_TEXT("Lock Released %d\n"), r);
    return r;
  }

  int Replication_Service::threads() const {
    return FTRTEC::threads;
  }
}

TAO_END_VERSIONED_NAMESPACE_DECL

ACE_FACTORY_NAMESPACE_DEFINE (
  TAO_FTRTEC,
  Replication_Service,
  FTRTEC::Replication_Service)

ACE_STATIC_SVC_DEFINE (
  Replication_Service,
  ACE_TEXT ("FTRTEC_Replication"),
  ACE_SVC_OBJ_T,
  &ACE_SVC_NAME (Replication_Service),
  ACE_Service_Type::DELETE_THIS
  | ACE_Service_Type::DELETE_OBJ,
  0)
Exemplo n.º 3
0
          // the object reference of the naming service.
          obj = name_context._retn ();
        }
    }
  catch (const ::CORBA::SystemException& ex)
    {
      if (TAO_debug_level >= 4)
        {
          ex._tao_print_exception ("CORBANAME_Parser");
        }
    }

  return obj;
}


ACE_STATIC_SVC_DEFINE (TAO_CORBANAME_Parser,
                       ACE_TEXT ("CORBANAME_Parser"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_CORBANAME_Parser),
                       ACE_Service_Type::DELETE_THIS |
                                  ACE_Service_Type::DELETE_OBJ,
                       0)

ACE_FACTORY_DEFINE (TAO, TAO_CORBANAME_Parser)

TAO_END_VERSIONED_NAMESPACE_DECL

#endif /* TAO_HAS_CORBANAME_PARSER == 1 */

Exemplo n.º 4
0
{
  (*any) <<= value;
}

int
TAO_AnyTypeCode_Adapter_Impl::Initializer (void)
{
  // The TAO::Unknown_IDL_Type::lock_i () is a PRIVATE thread unsafe singleton
  // which we need to initialise before Unknown_IDL_Types are used in a
  // threaded environment. This singleton is called for every constructed
  // Unknown_IDL_Type, so just create a throw-a-way from a null typecode.
  TAO::Unknown_IDL_Type singleton_initaliser (0);
  ACE_UNUSED_ARG (singleton_initaliser);

  return ACE_Service_Config::process_directive (
        ace_svc_desc_TAO_AnyTypeCode_Adapter_Impl);
}

ACE_STATIC_SVC_DEFINE (
  TAO_AnyTypeCode_Adapter_Impl,
  ACE_TEXT ("AnyTypeCode_Adapter"),
  ACE_SVC_OBJ_T,
  &ACE_SVC_NAME (TAO_AnyTypeCode_Adapter_Impl),
  ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
  0)

ACE_FACTORY_DEFINE (TAO_AnyTypeCode, TAO_AnyTypeCode_Adapter_Impl)

TAO_END_VERSIONED_NAMESPACE_DECL

  if (npm == TAO::Portable_Server::Cached_Policies::
             CLIENT_PROPAGATED_NETWORK_PRIORITY)
    {
      if (nph != 0)
        {
          dscp_codepoint = nph->get_dscp_codepoint (request_service_context);
        }
    }
  else if (npm == TAO::Portable_Server::Cached_Policies::
                  SERVER_DECLARED_NETWORK_PRIORITY)
    {
      dscp_codepoint = poa.cached_policies ().reply_diffserv_codepoint ();
    }

  TAO_Connection_Handler *connection_handler =
    req.transport ()->connection_handler ();
  connection_handler->set_dscp_codepoint (dscp_codepoint);
}


ACE_FACTORY_DEFINE (TAO_DiffServPolicy, TAO_DiffServ_Network_Priority_Hook)
ACE_STATIC_SVC_DEFINE (TAO_DiffServ_Network_Priority_Hook,
                       ACE_TEXT ("TAO_Network_Priority_Hook"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_DiffServ_Network_Priority_Hook),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 6
0
TAO_EC_TPC_Factory::create_proxy_push_supplier (TAO_EC_Event_Channel_Base *ec)
{
  if (TAO_EC_TPC_debug_level > 0)
    ORBSVCS_DEBUG ((LM_DEBUG, "EC (%P|%t) EC_TPC_Factory::create_proxy_push_supplier\n"));
  return new TAO_EC_TPC_ProxyPushSupplier (ec, this->consumer_validate_connection_);
}


TAO_EC_ProxyPushConsumer*
TAO_EC_TPC_Factory::create_proxy_push_consumer (TAO_EC_Event_Channel_Base *ec)
{
  if (TAO_EC_TPC_debug_level > 0)
    ORBSVCS_DEBUG ((LM_DEBUG, "EC (%P|%t) EC_TPC_Factory::create_proxy_push_consumer\n"));
  return new TAO_EC_TPC_ProxyPushConsumer (ec);
}

TAO_END_VERSIONED_NAMESPACE_DECL

// ****************************************************************

ACE_STATIC_SVC_DEFINE (TAO_EC_TPC_Factory,
                       ACE_TEXT ("EC_Factory"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_EC_TPC_Factory),
                       ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
                       0)
ACE_FACTORY_DEFINE (TAO_RTEvent_Serv, TAO_EC_TPC_Factory)

// ****************************************************************

Exemplo n.º 7
0
                  0);
  return connector;
}

int
TAO::HTIOP::Protocol_Factory::requires_explicit_endpoint (void) const
{
  return 0;
}


TAO_END_VERSIONED_NAMESPACE_DECL

ACE_STATIC_SVC_DEFINE (TAO_HTIOP_Protocol_Factory,
                       ACE_TEXT ("HTIOP_Factory"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_HTIOP_Protocol_Factory),
                       ACE_Service_Type::DELETE_THIS |
                       ACE_Service_Type::DELETE_OBJ,
                       0)


// Since the actual class instantiated by the factory is scoped inside a
// namespace, this macro is used in place of ACE_FACTORY_DEFINE, athough
// the declaration macro is the same. Note that the second argument must
// match the name class name used in the ACE_FACTORY_DECLARE, and the
// third argument is the fully scoped class to be instantiated.
ACE_FACTORY_NAMESPACE_DEFINE (HTIOP,
                              TAO_HTIOP_Protocol_Factory,
                              TAO::HTIOP::Protocol_Factory)
Exemplo n.º 8
0
}

int
Lorica_MapperRegistry::initialize(void)
{
	return ACE_Service_Config::process_directive(ace_svc_desc_Lorica_MapperRegistry);
}

bool
Lorica_MapperRegistry::poa_and_object_id(CORBA::Object_ptr ref,
					 CORBA::OctetSeq *& poaid,
					 PortableServer::ObjectId *& objid)
{
	if (this->mappers_ == 0) {
		poaid = new CORBA::OctetSeq;
		objid = new PortableServer::ObjectId;

		return false;
	}

	return this->mappers_->poa_and_object_id(ref, poaid, objid);
}

ACE_STATIC_SVC_DEFINE(Lorica_MapperRegistry,
		      ACE_TEXT("MapperRegistry"),
		      ACE_SVC_OBJ_T,
		      &ACE_SVC_NAME(Lorica_MapperRegistry),
		      ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
		      0)
ACE_FACTORY_DEFINE(Lorica_EvaluatorBase, Lorica_MapperRegistry)
{
  ACE_NEW (this->rt_invocation_endpoint_selector_,
           TAO_RT_Invocation_Endpoint_Selector);
}

RT_Endpoint_Selector_Factory::~RT_Endpoint_Selector_Factory (void)
{
  delete this->rt_invocation_endpoint_selector_;
}

TAO_Invocation_Endpoint_Selector *
RT_Endpoint_Selector_Factory::get_selector (void)
{
  return this->rt_invocation_endpoint_selector_;
}


// ****************************************************************

ACE_STATIC_SVC_DEFINE (RT_Endpoint_Selector_Factory,
                       ACE_TEXT ("RT_Endpoint_Selector_Factory"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (RT_Endpoint_Selector_Factory),
                       ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
                       0)
ACE_FACTORY_DEFINE (TAO_RTCORBA, RT_Endpoint_Selector_Factory)

TAO_END_VERSIONED_NAMESPACE_DECL

#endif /* TAO_HAS_CORBA_MESSAGING && TAO_HAS_CORBA_MESSAGING != 0 */
Exemplo n.º 10
0
        PortableInterceptor::ORBInitializer_var orb_initializer;
        orb_initializer = temp_orb_initializer;

        PortableInterceptor::register_orb_initializer (orb_initializer.in ());
    }
    catch (const ::CORBA::Exception& ex)
    {
        ex._tao_print_exception (
            "Unexpected exception caught while "
            "initializing the RTORB");
        return 1;
    }

    return 0;
}


/////////////////////////////////////////////////////////////////////

ACE_FACTORY_DEFINE (TAO_RTCORBA, TAO_RT_ORB_Loader)
ACE_STATIC_SVC_DEFINE (TAO_RT_ORB_Loader,
                       ACE_TEXT ("RT_ORB_Loader"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_RT_ORB_Loader),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
TAO_END_VERSIONED_NAMESPACE_DECL

#endif /* TAO_HAS_CORBA_MESSAGING && TAO_HAS_CORBA_MESSAGING != 0 */
Exemplo n.º 11
0
#include "tao/PortableServer/Object_Adapter_Factory.h"
#include "tao/PortableServer/Object_Adapter.h"
#include "tao/ORB_Core.h"

TAO_BEGIN_VERSIONED_NAMESPACE_DECL

TAO_Adapter*
TAO_Object_Adapter_Factory::create (TAO_ORB_Core *orb_core)
{
  TAO_Adapter* adapter = 0;
  ACE_NEW_RETURN (adapter,
                  TAO_Object_Adapter (orb_core->server_factory ()->
                                      active_object_map_creation_parameters (),
                                     *orb_core),
                  0);
  return adapter;
}


ACE_FACTORY_DEFINE (TAO_PortableServer, TAO_Object_Adapter_Factory)
ACE_STATIC_SVC_DEFINE (TAO_Object_Adapter_Factory,
                       ACE_TEXT ("TAO_Object_Adapter_Factory"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_Object_Adapter_Factory),
                       ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
                       0)

TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 12
0
  ACE::HTBP::Filter *filter = 0;
  if (inside)
    ACE_NEW_RETURN (filter,
                    ACE::HTBP::Inside_Squid_Filter (),0);
  else
    ACE_NEW_RETURN (filter,
                    ACE::HTBP::Outside_Squid_Filter (),0);
  return filter;
}

int
ACE::HTBP::Filter_Factory::init (int /* argc */,
                         ACE_TCHAR * /* argv */ [])
{
  return 0;
}

ACE_END_VERSIONED_NAMESPACE_DECL

ACE_STATIC_SVC_DEFINE (ACE_HTBP_Filter_Factory,
                       ACE_TEXT ("Filter_Factory"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (ACE_HTBP_Filter_Factory),
                       ACE_Service_Type::DELETE_THIS |
                       ACE_Service_Type::DELETE_OBJ,
                       0)

ACE_FACTORY_NAMESPACE_DEFINE (HTBP, ACE_HTBP_Filter_Factory,
                              ACE::HTBP::Filter_Factory)

Exemplo n.º 13
0
TAO_CSD_Strategy_Repository::Strategy_Node::add_node(Strategy_Node *node)
{
  if (this->next_)
    this->next_->add_node(node);
  else
    this->next_ = node;
}

TAO_CSD_Strategy_Repository::Strategy_Node *
TAO_CSD_Strategy_Repository::Strategy_Node::find(const ACE_CString &name)
{
  if (this->poa_name_ == name)
    return this;
  if (this->next_)
    return this->next_->find(name);
  return 0;
}


/////////////////////////////////////////////////////////////////////

ACE_FACTORY_DEFINE (TAO_CSD_FW, TAO_CSD_Strategy_Repository)
ACE_STATIC_SVC_DEFINE (TAO_CSD_Strategy_Repository,
                       ACE_TEXT ("TAO_CSD_Strategy_Repository"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_CSD_Strategy_Repository),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 14
0
                          CORBA::SystemException::_tao_minor_code (
                            TAO::VMCID,
                            ENOMEM),
                          CORBA::COMPLETED_NO));

      PortableInterceptor::ORBInitializer_var initializer = tmp;

      PortableInterceptor::register_orb_initializer (initializer.in ());
    }
  catch (const CORBA::Exception& ex)
    {
      ex._tao_print_exception (
        "Unable to register LB_ClientComponent ORB ""initializer.");
      return -1;
    }

  return 0;
}

TAO_END_VERSIONED_NAMESPACE_DECL

ACE_STATIC_SVC_DEFINE (TAO_LB_ClientComponent,
                       ACE_TEXT ("LB_ClientComponent"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_LB_ClientComponent),
                       ACE_Service_Type::DELETE_THIS |
                                  ACE_Service_Type::DELETE_OBJ,
                       0)

ACE_FACTORY_DEFINE (TAO_LoadBalancing, TAO_LB_ClientComponent)
                   ACE_TEXT ("(%P|%t) ERROR, Unable to get %s\n"),
                   strategy_name));

      return strategy;
    }

    void
    IdAssignmentStrategyFactoryImpl::destroy (IdAssignmentStrategy *)
    {
      // Noop because both types are singletons
    }

  }
}



ACE_STATIC_SVC_DEFINE (
  IdAssignmentStrategyFactoryImpl,
  ACE_TEXT ("IdAssignmentStrategyFactory"),
  ACE_SVC_OBJ_T,
  &ACE_SVC_NAME (IdAssignmentStrategyFactoryImpl),
  ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
  0)

ACE_FACTORY_NAMESPACE_DEFINE (
  ACE_Local_Service,
  IdAssignmentStrategyFactoryImpl,
  TAO::Portable_Server::IdAssignmentStrategyFactoryImpl)
TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 16
0
// -*- C++ -*-
// $Id$

#include "WUCS4_UTF16_Factory.h"

ACE_STATIC_SVC_DEFINE (WUCS4_UTF16_Factory,
                       ACE_TEXT ("WUCS4_UTF16_Factory"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (WUCS4_UTF16_Factory),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
ACE_FACTORY_DEFINE (UCS4_UTF16, WUCS4_UTF16_Factory)
Exemplo n.º 17
0
{
        return 0;
}

void
TAO_Notify_Tests_Command_Builder::_register (ACE_CString command_factory_name, TAO_Notify_Tests_Command_Factory* command_factory)
{
  if (this->factory_map_.bind (command_factory_name, command_factory) == -1)
    ACE_DEBUG ((LM_DEBUG, "Failed to register command factory for %s\n", command_factory_name.c_str ()));
  else
    ACE_DEBUG ((LM_DEBUG, "Registered command factory for %s\n", command_factory_name.c_str ()));
}

void
TAO_Notify_Tests_Command_Builder::execute (void)
{
  if (this->start_command_)
    this->start_command_->execute ();
}

ACE_STATIC_SVC_DEFINE(TAO_Notify_Tests_Command_Builder,
                      TAO_Notify_Tests_Name::command_builder,
                      ACE_SVC_OBJ_T,
                      &ACE_SVC_NAME (TAO_Notify_Tests_Command_Builder),
                      ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
                      0)

ACE_FACTORY_DEFINE (TAO_NOTIFY_TEST, TAO_Notify_Tests_Command_Builder)

ACE_STATIC_SVC_REQUIRE (TAO_Notify_Tests_Command_Builder)
Exemplo n.º 18
0
  namespace Monitor_Control
  {
    Monitor_Admin&
    Monitor_Admin_Manager::admin (void)
    {
      return this->admin_;
    }

    int
    Monitor_Admin_Manager::Initializer (void)
    {
      return
        ACE_Service_Config::process_directive (ace_svc_desc_MC_ADMINMANAGER);
    }
  }
}

ACE_END_VERSIONED_NAMESPACE_DECL

ACE_STATIC_SVC_DEFINE (MC_ADMINMANAGER,
                       ACE_TEXT ("MC_ADMINMANAGER"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (MC_ADMINMANAGER),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
ACE_FACTORY_DEFINE (ACE, MC_ADMINMANAGER)

#endif /* ACE_HAS_MONITOR_FRAMEWORK==1 */

Exemplo n.º 19
0
        ACE_ERROR ((LM_ERROR, "%p\n", "Asynch_Thread_Pool_Task::open"));
}

int
Asynch_Thread_Pool_Task::svc (void)
{
    for (;;)
        if (this->proactor_.handle_events () == -1)
            ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "ACE_Proactor::handle_events"),
                              -1);

    return 0;
}

#endif /* ACE_WIN32 */

// Define the factory function.
ACE_SVC_FACTORY_DEFINE (HTTP_Server)

// Define the object that describes the service.
ACE_STATIC_SVC_DEFINE (HTTP_Server, "HTTP_Server", ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (HTTP_Server),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ, 0)

#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION)
template class ACE_LOCK_SOCK_Acceptor<ACE_SYNCH_MUTEX>;
#elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA)
#pragma instantiate ACE_LOCK_SOCK_Acceptor<ACE_SYNCH_MUTEX>
#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */
    }

    void
    IdUniquenessStrategyUniqueFactoryImpl::destroy (
      IdUniquenessStrategy *strategy
      )
    {
      strategy->strategy_cleanup ();

      delete strategy;
    }

  }
}


ACE_STATIC_SVC_DEFINE (
  IdUniquenessStrategyUniqueFactoryImpl,
  ACE_TEXT ("IdUniquenessStrategyUniqueFactory"),
  ACE_SVC_OBJ_T,
  &ACE_SVC_NAME (IdUniquenessStrategyUniqueFactoryImpl),
  ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
  0)

ACE_FACTORY_NAMESPACE_DEFINE (
  ACE_Local_Service,
  IdUniquenessStrategyUniqueFactoryImpl,
  TAO::Portable_Server::IdUniquenessStrategyUniqueFactoryImpl)

TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 21
0
                           (ACE_TEXT ("-CIAOLogFile"))))
        {
            this->filename_ = current_arg;

            arg_shifter.consume_arg ();
        }
        else
        {
            // Can't interpret this argument.  Move on to the next
            // argument.  Any arguments that don't match are ignored
            // so that the caller can still use them.
            arg_shifter.ignore_arg ();
        }
    }
}

int
CIAO::Logger_Service::Initializer (void)
{
    return ACE_Service_Config::process_directive (ace_svc_desc_CIAO_LOGGER_SERVICE);
}

ACE_STATIC_SVC_DEFINE (CIAO_LOGGER_SERVICE,
                       ACE_TEXT ("CIAO_Logger"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (CIAO_LOGGER_SERVICE),
                       ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
                       0)
ACE_FACTORY_DEFINE (CIAO_Logger, CIAO_LOGGER_SERVICE)

Exemplo n.º 22
0
      PortableInterceptor::register_orb_initializer (orb_initializer.in ());
    }
  catch (const ::CORBA::Exception& ex)
    {
      if (TAO_debug_level > 0)
        {
          ex._tao_print_exception ("Caught exception:");
        }
      return -1;
    }

  ACE_Service_Config::process_directive
    (ace_svc_desc_TAO_Endpoint_Acceptor_Filter_Factory,1); // force replacement

  return 0;
}


/////////////////////////////////////////////////////////////////////

ACE_FACTORY_DEFINE (TAO_EndpointPolicy, TAO_EndpointPolicy_Initializer)
ACE_STATIC_SVC_DEFINE (TAO_EndpointPolicy_Initializer,
                       ACE_TEXT ("EndpointPolicy_Initializer"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_EndpointPolicy_Initializer),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 23
0
}

void
ACE_Logging_Strategy::log_msg (ACE_Log_Msg *log_msg)
{
  this->log_msg_  = log_msg;
}

ACE_END_VERSIONED_NAMESPACE_DECL

// The following is a "Factory" used by the ACE_Service_Config and
// svc.conf file to dynamically initialize the state of the
// Logging_Strategy.

ACE_STATIC_SVC_DEFINE (ACE_Logging_Strategy,
                       ACE_TEXT ("Logging_Strategy"),
                       ACE_Service_Type::SERVICE_OBJECT,
                       &ACE_SVC_NAME (ACE_Logging_Strategy),
                       ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
                       0)

ACE_FACTORY_DEFINE (ACE, ACE_Logging_Strategy)

// _get_dll_unload_policy() prevents ACE from being unloaded and having its
// framework components run down if/when the Logging Strategy is unloaded.
extern "C" ACE_Export int
_get_dll_unload_policy()
{
  return ACE_DLL_UNLOAD_POLICY_LAZY;
}
Exemplo n.º 24
0
      catch (const CORBA::Exception& ex)
      {
        ex._tao_print_exception (
          "Unexpected exception caught while ""initializing the TransactionDepth");
        return 1;
      }

      return 0;
  }
}

TAO_END_VERSIONED_NAMESPACE_DECL

  /////////////////////////////////////////////////////////////////////

ACE_FACTORY_NAMESPACE_DEFINE (
  TAO_FTRT,
  FTRT_ClientORB_Loader,
  TAO_FTRT::FTRT_ClientORB_Loader)

ACE_STATIC_SVC_DEFINE (
  FTRT_ClientORB_Loader,
  ACE_TEXT ("FTRT_ClientORB_Service"),
  ACE_SVC_OBJ_T,
  &ACE_SVC_NAME (FTRT_ClientORB_Loader),
  ACE_Service_Type::DELETE_THIS
  | ACE_Service_Type::DELETE_OBJ,
  0)


Exemplo n.º 25
0
}

int
Lorica_GenericLoader::init(int argc,
			   ACE_TCHAR *argv[])
{
	this->Lorica_EvaluatorLoader::init(argc, argv);

	Lorica::ProxyMapper *mapper = new Lorica::GenericMapper(false, *this->mapperRegistry_);

	this->mapperRegistry_->set_generic_mapper(mapper);

	return 1;
}

// Shared object finalizer
int
Lorica_GenericLoader::fini(void)
{
	return this->Lorica_EvaluatorLoader::fini();
}

ACE_STATIC_SVC_DEFINE(Lorica_GenericLoader,
		      ACE_TEXT ("Lorica_GenericLoader"),
		      ACE_SVC_OBJ_T,
		      &ACE_SVC_NAME (Lorica_GenericLoader),
		      ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
		      0)

ACE_FACTORY_DEFINE(Lorica_GenericEvaluator, Lorica_GenericLoader)
        // Add an argument to the NVList.
        result->add_value (params[i].name.in (), value, flags);
    }
}

#endif /*TAO_HAS_MINIMUM_CORBA*/
// *********************************************************************

// Initialization and registration of dynamic service object.

int
TAO_IFR_Client_Adapter_Impl::Initializer (void)
{
    TAO_ORB_Core::ifr_client_adapter_name ("Concrete_IFR_Client_Adapter");

    return ACE_Service_Config::process_directive (ace_svc_desc_TAO_IFR_Client_Adapter_Impl);
}


ACE_STATIC_SVC_DEFINE (
    TAO_IFR_Client_Adapter_Impl,
    ACE_TEXT ("Concrete_IFR_Client_Adapter"),
    ACE_SVC_OBJ_T,
    &ACE_SVC_NAME (TAO_IFR_Client_Adapter_Impl),
    ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
    0
)

ACE_FACTORY_DEFINE (TAO_IFR_CLIENT, TAO_IFR_Client_Adapter_Impl)
TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 27
0
                          TAO::VMCID,
                          ENOMEM),
                          CORBA::COMPLETED_NO));

      PortableInterceptor::ORBInitializer_var orb_initializer =
        temp_orb_initializer;

      PortableInterceptor::register_orb_initializer (orb_initializer.in ());
    }
  catch (const ::CORBA::Exception& ex)
    {
      ex._tao_print_exception (
        "Unexpected exception caught while initializing the RTScheduler:");
      return 1;
    }

  return 0;
}

/////////////////////////////////////////////////////////////////////

ACE_FACTORY_DEFINE (TAO_RTScheduler, TAO_RTScheduler_Loader)
ACE_STATIC_SVC_DEFINE (TAO_RTScheduler_Loader,
                       ACE_TEXT ("RTScheduler_Loader"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (TAO_RTScheduler_Loader),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
TAO_END_VERSIONED_NAMESPACE_DECL
Exemplo n.º 28
0
// -*- C++ -*-

//=============================================================================
/**
 *  @file    Wchar_IBM1047_ISO8859_Factory.cpp
 *
 *  $Id: Wchar_IBM1047_ISO8859_Factory.cpp 93650 2011-03-28 08:44:53Z johnnyw $
 *
 *  A tempate instantiation of the codeset translator factory from TAO. This
 *  one loads a modified version of ACE's IBM1047 (EBCDIC) to ISO8859 (ASCII)
 *  translator. In this case, wchars and wstrings are translated rather than
 *  strings and chars.
 *
 *
 *  @author   Phil Mesnier <*****@*****.**>
 */
//=============================================================================


#include "Wchar_IBM1047_ISO8859_Factory.h"
#include "ace/Log_Msg.h"

ACE_STATIC_SVC_DEFINE (Wchar_IBM1047_ISO8859_Factory,
                       ACE_TEXT ("Wchar_IBM1047_ISO8859_Factory"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (Wchar_IBM1047_ISO8859_Factory),
                       ACE_Service_Type::DELETE_THIS
                       | ACE_Service_Type::DELETE_OBJ,
                       0)
ACE_FACTORY_DEFINE (IBM1047_ISO8859, Wchar_IBM1047_ISO8859_Factory)
Exemplo n.º 29
0
                         "\t[-d] (enable debugging)\n"
                         "\t[-h nameserver host]\n"
                         "\t[-l namespace directory]\n"
                         "\t[-P processname]\n"
                         "\t[-p nameserver port]\n"
                         "\t[-s database name]\n"
                         "\t[-b base address]\n"
                         "\t[-v] (verbose)\n"
                         "\t[-r] (use Win32 Registry)\n",
                         argv[0]);
        /* NOTREACHED */
        break;
      }
}

ACE_END_VERSIONED_NAMESPACE_DECL

// The following Factory is used by the ACE_Service_Config and
// svc.conf file to dynamically initialize the state of the Name
// Server client.

ACE_FACTORY_DEFINE (ACE, ACE_Naming_Context)
ACE_STATIC_SVC_DEFINE (ACE_Naming_Context,
                       ACE_TEXT ("ACE_Naming_Context"),
                       ACE_SVC_OBJ_T,
                       &ACE_SVC_NAME (ACE_Naming_Context),
                       ACE_Service_Type::DELETE_THIS |
                       ACE_Service_Type::DELETE_OBJ,
                       0)
ACE_STATIC_SVC_REQUIRE (ACE_Naming_Context)
Exemplo n.º 30
0
{
char
IdAssignmentStrategySystem::id_assignment_key_type (void) const
{
    return 'S';
}

bool
IdAssignmentStrategySystem::has_system_id (void) const
{
    return true;
}
}
}

ACE_FACTORY_NAMESPACE_DEFINE (
    ACE_Local_Service,
    IdAssignmentStrategySystem,
    TAO::Portable_Server::IdAssignmentStrategySystem)

ACE_STATIC_SVC_DEFINE (
    IdAssignmentStrategySystem,
    ACE_TEXT ("IdAssignmentStrategySystem"),
    ACE_SVC_OBJ_T,
    &ACE_SVC_NAME (IdAssignmentStrategySystem),
    ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ,
    0)

TAO_END_VERSIONED_NAMESPACE_DECL