00001
00002
00003 #include "orbsvcs/Notify/RT_Builder.h"
00004
00005 #include "ace/Auto_Ptr.h"
00006 #include "ace/Dynamic_Service.h"
00007 #include "orbsvcs/Notify/ETCL_FilterFactory.h"
00008 #include "orbsvcs/Notify/RT_POA_Helper.h"
00009 #include "orbsvcs/Notify/Properties.h"
00010 #include "orbsvcs/NotifyExtC.h"
00011 #include "orbsvcs/Notify/Object.h"
00012
00013 ACE_RCSID (RT_Notify,
00014 TAO_Notify_RT_Builder,
00015 "RT_Builder.cpp,v 1.10 2006/03/14 06:14:34 jtc Exp")
00016
00017 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00018
00019 TAO_Notify_RT_Builder::TAO_Notify_RT_Builder (void)
00020 {
00021 }
00022
00023 TAO_Notify_RT_Builder::~TAO_Notify_RT_Builder ()
00024 {
00025 }
00026
00027 void
00028 TAO_Notify_RT_Builder::apply_thread_pool_concurrency (TAO_Notify_Object& object
00029 , const NotifyExt::ThreadPoolParams& tp_params ACE_ENV_ARG_DECL)
00030 {
00031 TAO_Notify_RT_POA_Helper* proxy_poa = 0;
00032
00033
00034 ACE_NEW_THROW_EX (proxy_poa,
00035 TAO_Notify_RT_POA_Helper (),
00036 CORBA::NO_MEMORY ());
00037 ACE_CHECK;
00038
00039 ACE_Auto_Ptr<TAO_Notify_POA_Helper> auto_proxy_poa (proxy_poa);
00040
00041 PortableServer::POA_var default_poa = TAO_Notify_PROPERTIES::instance ()->default_poa ();
00042
00043 proxy_poa->init (default_poa.in (), tp_params ACE_ENV_ARG_PARAMETER);
00044 ACE_CHECK;
00045
00046
00047 object.set_proxy_poa (auto_proxy_poa.release ());
00048 }
00049
00050 void
00051 TAO_Notify_RT_Builder::apply_lane_concurrency (TAO_Notify_Object& object
00052 , const NotifyExt::ThreadPoolLanesParams& tpl_params ACE_ENV_ARG_DECL)
00053 {
00054 TAO_Notify_RT_POA_Helper* proxy_poa = 0;
00055
00056
00057 ACE_NEW_THROW_EX (proxy_poa,
00058 TAO_Notify_RT_POA_Helper (),
00059 CORBA::NO_MEMORY ());
00060 ACE_CHECK;
00061
00062 ACE_Auto_Ptr<TAO_Notify_POA_Helper> auto_proxy_poa (proxy_poa);
00063
00064 PortableServer::POA_var default_poa = TAO_Notify_PROPERTIES::instance ()->default_poa ();
00065
00066 proxy_poa->init (default_poa.in (), tpl_params ACE_ENV_ARG_PARAMETER);
00067 ACE_CHECK;
00068
00069
00070 object.set_proxy_poa (auto_proxy_poa.release ());
00071 }
00072
00073 TAO_END_VERSIONED_NAMESPACE_DECL