00001 // $Id: Connector_Impl.cpp 78931 2007-07-18 09:59:36Z johnnyw $ 00002 00003 #ifndef TAO_CONNECTOR_IMPL_CPP 00004 #define TAO_CONNECTOR_IMPL_CPP 00005 00006 #include "tao/Connector_Impl.h" 00007 00008 #if !defined (ACE_LACKS_PRAGMA_ONCE) 00009 # pragma once 00010 #endif /* ACE_LACKS_PRAGMA_ONCE */ 00011 00012 TAO_BEGIN_VERSIONED_NAMESPACE_DECL 00013 00014 template <class SVC_HANDLER> 00015 TAO_Connect_Creation_Strategy<SVC_HANDLER>:: 00016 TAO_Connect_Creation_Strategy (ACE_Thread_Manager* t, 00017 TAO_ORB_Core *orb_core) 00018 : ACE_Creation_Strategy <SVC_HANDLER> (t), 00019 orb_core_ (orb_core) 00020 { 00021 00022 } 00023 00024 template <class SVC_HANDLER> int 00025 TAO_Connect_Creation_Strategy<SVC_HANDLER>::make_svc_handler (SVC_HANDLER *&sh) 00026 { 00027 if (sh == 0) 00028 ACE_NEW_RETURN (sh, 00029 SVC_HANDLER (this->orb_core_), 00030 -1); 00031 00032 // We add to the #REFCOUNT# since the Connector needs this. See 00033 // Connector::make_connection() for details. 00034 sh->add_reference (); 00035 00036 // At this point, the #REFCOUNT# is two. 00037 00038 return 0; 00039 } 00040 00041 00042 //////////////////////////////////////////////////////////////// 00043 00044 template <class SVC_HANDLER> 00045 TAO_Connect_Concurrency_Strategy<SVC_HANDLER>:: 00046 TAO_Connect_Concurrency_Strategy (TAO_ORB_Core *orb_core) 00047 : orb_core_ (orb_core) 00048 { 00049 } 00050 00051 template <class SVC_HANDLER> int 00052 TAO_Connect_Concurrency_Strategy<SVC_HANDLER>:: 00053 activate_svc_handler (SVC_HANDLER *sh, 00054 void *arg) 00055 { 00056 return ACE_Concurrency_Strategy<SVC_HANDLER>::activate_svc_handler (sh, 00057 arg); 00058 } 00059 00060 TAO_END_VERSIONED_NAMESPACE_DECL 00061 00062 #endif /* TAO_CONNECTOR_IMPL_CPP */