EC_RTCORBA_Factory.cpp

Go to the documentation of this file.
00001 // EC_RTCORBA_Factory.cpp,v 1.9 2006/03/14 06:14:25 jtc Exp
00002 
00003 #include "orbsvcs/Event/EC_RTCORBA_Dispatching.h"
00004 #include "orbsvcs/Event/EC_RTCORBA_Factory.h"
00005 
00006 #include "tao/RTCORBA/Priority_Mapping_Manager.h"
00007 
00008 ACE_RCSID(Event, EC_RTCORBA_Factory, "EC_RTCORBA_Factory.cpp,v 1.9 2006/03/14 06:14:25 jtc Exp")
00009 
00010 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00011 
00012 TAO_EC_RTCORBA_Factory::
00013     TAO_EC_RTCORBA_Factory (TAO_EC_Factory *body,
00014                             const RTCORBA::ThreadpoolLanes &lanes)
00015   : body_ (body)
00016   , lanes_ (lanes)
00017 {
00018 }
00019 
00020 TAO_EC_RTCORBA_Factory::~TAO_EC_RTCORBA_Factory (void)
00021 {
00022 }
00023 
00024 
00025 int
00026 TAO_EC_RTCORBA_Factory::init (int argc, char* argv[])
00027 {
00028   return this->body_->init (argc, argv);
00029 }
00030 
00031 int
00032 TAO_EC_RTCORBA_Factory::fini (void)
00033 {
00034   return this->body_->fini ();
00035 }
00036 
00037 // ****************************************************************
00038 
00039 TAO_EC_Dispatching*
00040 TAO_EC_RTCORBA_Factory::create_dispatching (TAO_EC_Event_Channel_Base *)
00041 {
00042   TAO_EC_Dispatching *dispatching = 0;
00043   ACE_DECLARE_NEW_CORBA_ENV;
00044   ACE_TRY
00045     {
00046       // @@ The ORBId could be important!!!
00047       int argc = 0;
00048       CORBA::ORB_var orb =
00049         CORBA::ORB_init (argc, 0, ""
00050                          ACE_ENV_ARG_PARAMETER);
00051       ACE_TRY_CHECK;
00052 
00053       CORBA::Object_var obj =
00054         orb->resolve_initial_references ("PriorityMappingManager"
00055                                          ACE_ENV_ARG_PARAMETER);
00056       ACE_TRY_CHECK;
00057 
00058       RTCORBA::PriorityMappingManager_var priority_mapping_manager =
00059         RTCORBA::PriorityMappingManager::_narrow (obj.in ()
00060                                                   ACE_ENV_ARG_PARAMETER);
00061       ACE_TRY_CHECK;
00062 
00063       RTCORBA::PriorityMapping *priority_mapping =
00064         priority_mapping_manager->mapping ();
00065 
00066       obj =
00067         orb->resolve_initial_references ("RTCurrent"
00068                                          ACE_ENV_ARG_PARAMETER);
00069       ACE_TRY_CHECK;
00070 
00071       RTCORBA::Current_var current =
00072         RTCORBA::Current::_narrow (obj.in ()
00073                                    ACE_ENV_ARG_PARAMETER);
00074       ACE_TRY_CHECK;
00075 
00076       ACE_NEW_RETURN (dispatching,
00077                       TAO_EC_RTCORBA_Dispatching (this->lanes_,
00078                                                   priority_mapping,
00079                                                   current.in ()),
00080                       0);
00081     }
00082   ACE_CATCHANY
00083     {
00084     }
00085   ACE_ENDTRY;
00086 
00087   return dispatching;
00088 }
00089 
00090 void
00091 TAO_EC_RTCORBA_Factory::destroy_dispatching (TAO_EC_Dispatching *x)
00092 {
00093   this->body_->destroy_dispatching (x);
00094 }
00095 
00096 TAO_EC_Filter_Builder*
00097 TAO_EC_RTCORBA_Factory::create_filter_builder (TAO_EC_Event_Channel_Base *ec)
00098 {
00099   return this->body_->create_filter_builder (ec);
00100 }
00101 
00102 void
00103 TAO_EC_RTCORBA_Factory::destroy_filter_builder (TAO_EC_Filter_Builder *x)
00104 {
00105   this->body_->destroy_filter_builder (x);
00106 }
00107 
00108 TAO_EC_Supplier_Filter_Builder*
00109 TAO_EC_RTCORBA_Factory::create_supplier_filter_builder (TAO_EC_Event_Channel_Base *ec)
00110 {
00111   return this->body_->create_supplier_filter_builder (ec);
00112 }
00113 
00114 void
00115 TAO_EC_RTCORBA_Factory::destroy_supplier_filter_builder (TAO_EC_Supplier_Filter_Builder *x)
00116 {
00117   this->body_->destroy_supplier_filter_builder (x);
00118 }
00119 
00120 TAO_EC_ConsumerAdmin*
00121 TAO_EC_RTCORBA_Factory::create_consumer_admin (TAO_EC_Event_Channel_Base *ec)
00122 {
00123   return this->body_->create_consumer_admin (ec);
00124 }
00125 
00126 void
00127 TAO_EC_RTCORBA_Factory::destroy_consumer_admin (TAO_EC_ConsumerAdmin *x)
00128 {
00129   this->body_->destroy_consumer_admin (x);
00130 }
00131 
00132 TAO_EC_SupplierAdmin*
00133 TAO_EC_RTCORBA_Factory::create_supplier_admin (TAO_EC_Event_Channel_Base *ec)
00134 {
00135   return this->body_->create_supplier_admin (ec);
00136 }
00137 
00138 void
00139 TAO_EC_RTCORBA_Factory::destroy_supplier_admin (TAO_EC_SupplierAdmin *x)
00140 {
00141   this->body_->destroy_supplier_admin (x);
00142 }
00143 
00144 TAO_EC_ProxyPushSupplier*
00145 TAO_EC_RTCORBA_Factory::create_proxy_push_supplier (TAO_EC_Event_Channel_Base *ec)
00146 {
00147   return this->body_->create_proxy_push_supplier (ec);
00148 }
00149 
00150 void
00151 TAO_EC_RTCORBA_Factory::destroy_proxy_push_supplier (TAO_EC_ProxyPushSupplier *x)
00152 {
00153   this->body_->destroy_proxy_push_supplier (x);
00154 }
00155 
00156 TAO_EC_ProxyPushConsumer*
00157 TAO_EC_RTCORBA_Factory::create_proxy_push_consumer (TAO_EC_Event_Channel_Base *ec)
00158 {
00159   return this->body_->create_proxy_push_consumer (ec);
00160 }
00161 
00162 void
00163 TAO_EC_RTCORBA_Factory::destroy_proxy_push_consumer (TAO_EC_ProxyPushConsumer *x)
00164 {
00165   this->body_->destroy_proxy_push_consumer (x);
00166 }
00167 
00168 TAO_EC_Timeout_Generator*
00169 TAO_EC_RTCORBA_Factory::create_timeout_generator (TAO_EC_Event_Channel_Base *ec)
00170 {
00171   return this->body_->create_timeout_generator (ec);
00172 }
00173 
00174 void
00175 TAO_EC_RTCORBA_Factory::destroy_timeout_generator (TAO_EC_Timeout_Generator *x)
00176 {
00177   this->body_->destroy_timeout_generator (x);
00178 }
00179 
00180 TAO_EC_ObserverStrategy*
00181 TAO_EC_RTCORBA_Factory::create_observer_strategy (TAO_EC_Event_Channel_Base *ec)
00182 {
00183   return this->body_->create_observer_strategy (ec);
00184 }
00185 
00186 void
00187 TAO_EC_RTCORBA_Factory::destroy_observer_strategy (TAO_EC_ObserverStrategy *x)
00188 {
00189   this->body_->destroy_observer_strategy (x);
00190 }
00191 
00192 TAO_EC_Scheduling_Strategy*
00193 TAO_EC_RTCORBA_Factory::create_scheduling_strategy (TAO_EC_Event_Channel_Base *ec)
00194 {
00195   return this->body_->create_scheduling_strategy (ec);
00196 }
00197 
00198 void
00199 TAO_EC_RTCORBA_Factory::destroy_scheduling_strategy (TAO_EC_Scheduling_Strategy* x)
00200 {
00201   this->body_->destroy_scheduling_strategy (x);
00202 }
00203 
00204 TAO_EC_ProxyPushConsumer_Collection*
00205 TAO_EC_RTCORBA_Factory::create_proxy_push_consumer_collection (TAO_EC_Event_Channel_Base *ec)
00206 {
00207   return this->body_->create_proxy_push_consumer_collection (ec);
00208 }
00209 
00210 void
00211 TAO_EC_RTCORBA_Factory::destroy_proxy_push_consumer_collection (TAO_EC_ProxyPushConsumer_Collection *x)
00212 {
00213   this->body_->destroy_proxy_push_consumer_collection (x);
00214 }
00215 
00216 TAO_EC_ProxyPushSupplier_Collection*
00217 TAO_EC_RTCORBA_Factory::create_proxy_push_supplier_collection (TAO_EC_Event_Channel_Base *ec)
00218 {
00219   return this->body_->create_proxy_push_supplier_collection (ec);
00220 }
00221 
00222 void
00223 TAO_EC_RTCORBA_Factory::destroy_proxy_push_supplier_collection (TAO_EC_ProxyPushSupplier_Collection *x)
00224 {
00225   this->body_->destroy_proxy_push_supplier_collection (x);
00226 }
00227 
00228 ACE_Lock*
00229 TAO_EC_RTCORBA_Factory::create_consumer_lock (void)
00230 {
00231   return this->body_->create_consumer_lock ();
00232 }
00233 
00234 void
00235 TAO_EC_RTCORBA_Factory::destroy_consumer_lock (ACE_Lock* x)
00236 {
00237   this->body_->destroy_consumer_lock (x);
00238 }
00239 
00240 ACE_Lock*
00241 TAO_EC_RTCORBA_Factory::create_supplier_lock (void)
00242 {
00243   return this->body_->create_supplier_lock ();
00244 }
00245 
00246 void
00247 TAO_EC_RTCORBA_Factory::destroy_supplier_lock (ACE_Lock* x)
00248 {
00249   this->body_->destroy_supplier_lock (x);
00250 }
00251 
00252 TAO_EC_ConsumerControl*
00253 TAO_EC_RTCORBA_Factory::create_consumer_control (TAO_EC_Event_Channel_Base* ec)
00254 {
00255   return this->body_->create_consumer_control (ec);
00256 }
00257 
00258 void
00259 TAO_EC_RTCORBA_Factory::destroy_consumer_control (TAO_EC_ConsumerControl* x)
00260 {
00261   this->body_->destroy_consumer_control (x);
00262 }
00263 
00264 TAO_EC_SupplierControl*
00265 TAO_EC_RTCORBA_Factory::create_supplier_control (TAO_EC_Event_Channel_Base* ec)
00266 {
00267   return this->body_->create_supplier_control (ec);
00268 }
00269 
00270 void
00271 TAO_EC_RTCORBA_Factory::destroy_supplier_control (TAO_EC_SupplierControl* x)
00272 {
00273   this->body_->destroy_supplier_control (x);
00274 }
00275 
00276 TAO_END_VERSIONED_NAMESPACE_DECL

Generated on Thu Nov 9 13:11:09 2006 for TAO_RTEvent by doxygen 1.3.6