EC_RTCORBA_Factory.cpp

Go to the documentation of this file.
00001 // $Id: EC_RTCORBA_Factory.cpp 76626 2007-01-26 13:50:03Z elliott_c $
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, "$Id: EC_RTCORBA_Factory.cpp 76626 2007-01-26 13:50:03Z elliott_c $")
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   try
00044     {
00045       // @@ The ORBId could be important!!!
00046       int argc = 0;
00047       CORBA::ORB_var orb =
00048         CORBA::ORB_init (argc, 0, "");
00049 
00050       CORBA::Object_var obj =
00051         orb->resolve_initial_references ("PriorityMappingManager");
00052 
00053       RTCORBA::PriorityMappingManager_var priority_mapping_manager =
00054         RTCORBA::PriorityMappingManager::_narrow (obj.in ());
00055 
00056       RTCORBA::PriorityMapping *priority_mapping =
00057         priority_mapping_manager->mapping ();
00058 
00059       obj =
00060         orb->resolve_initial_references ("RTCurrent");
00061 
00062       RTCORBA::Current_var current =
00063         RTCORBA::Current::_narrow (obj.in ());
00064 
00065       ACE_NEW_RETURN (dispatching,
00066                       TAO_EC_RTCORBA_Dispatching (this->lanes_,
00067                                                   priority_mapping,
00068                                                   current.in ()),
00069                       0);
00070     }
00071   catch (const CORBA::Exception&)
00072     {
00073     }
00074 
00075   return dispatching;
00076 }
00077 
00078 void
00079 TAO_EC_RTCORBA_Factory::destroy_dispatching (TAO_EC_Dispatching *x)
00080 {
00081   this->body_->destroy_dispatching (x);
00082 }
00083 
00084 TAO_EC_Filter_Builder*
00085 TAO_EC_RTCORBA_Factory::create_filter_builder (TAO_EC_Event_Channel_Base *ec)
00086 {
00087   return this->body_->create_filter_builder (ec);
00088 }
00089 
00090 void
00091 TAO_EC_RTCORBA_Factory::destroy_filter_builder (TAO_EC_Filter_Builder *x)
00092 {
00093   this->body_->destroy_filter_builder (x);
00094 }
00095 
00096 TAO_EC_Supplier_Filter_Builder*
00097 TAO_EC_RTCORBA_Factory::create_supplier_filter_builder (TAO_EC_Event_Channel_Base *ec)
00098 {
00099   return this->body_->create_supplier_filter_builder (ec);
00100 }
00101 
00102 void
00103 TAO_EC_RTCORBA_Factory::destroy_supplier_filter_builder (TAO_EC_Supplier_Filter_Builder *x)
00104 {
00105   this->body_->destroy_supplier_filter_builder (x);
00106 }
00107 
00108 TAO_EC_ConsumerAdmin*
00109 TAO_EC_RTCORBA_Factory::create_consumer_admin (TAO_EC_Event_Channel_Base *ec)
00110 {
00111   return this->body_->create_consumer_admin (ec);
00112 }
00113 
00114 void
00115 TAO_EC_RTCORBA_Factory::destroy_consumer_admin (TAO_EC_ConsumerAdmin *x)
00116 {
00117   this->body_->destroy_consumer_admin (x);
00118 }
00119 
00120 TAO_EC_SupplierAdmin*
00121 TAO_EC_RTCORBA_Factory::create_supplier_admin (TAO_EC_Event_Channel_Base *ec)
00122 {
00123   return this->body_->create_supplier_admin (ec);
00124 }
00125 
00126 void
00127 TAO_EC_RTCORBA_Factory::destroy_supplier_admin (TAO_EC_SupplierAdmin *x)
00128 {
00129   this->body_->destroy_supplier_admin (x);
00130 }
00131 
00132 TAO_EC_ProxyPushSupplier*
00133 TAO_EC_RTCORBA_Factory::create_proxy_push_supplier (TAO_EC_Event_Channel_Base *ec)
00134 {
00135   return this->body_->create_proxy_push_supplier (ec);
00136 }
00137 
00138 void
00139 TAO_EC_RTCORBA_Factory::destroy_proxy_push_supplier (TAO_EC_ProxyPushSupplier *x)
00140 {
00141   this->body_->destroy_proxy_push_supplier (x);
00142 }
00143 
00144 TAO_EC_ProxyPushConsumer*
00145 TAO_EC_RTCORBA_Factory::create_proxy_push_consumer (TAO_EC_Event_Channel_Base *ec)
00146 {
00147   return this->body_->create_proxy_push_consumer (ec);
00148 }
00149 
00150 void
00151 TAO_EC_RTCORBA_Factory::destroy_proxy_push_consumer (TAO_EC_ProxyPushConsumer *x)
00152 {
00153   this->body_->destroy_proxy_push_consumer (x);
00154 }
00155 
00156 TAO_EC_Timeout_Generator*
00157 TAO_EC_RTCORBA_Factory::create_timeout_generator (TAO_EC_Event_Channel_Base *ec)
00158 {
00159   return this->body_->create_timeout_generator (ec);
00160 }
00161 
00162 void
00163 TAO_EC_RTCORBA_Factory::destroy_timeout_generator (TAO_EC_Timeout_Generator *x)
00164 {
00165   this->body_->destroy_timeout_generator (x);
00166 }
00167 
00168 TAO_EC_ObserverStrategy*
00169 TAO_EC_RTCORBA_Factory::create_observer_strategy (TAO_EC_Event_Channel_Base *ec)
00170 {
00171   return this->body_->create_observer_strategy (ec);
00172 }
00173 
00174 void
00175 TAO_EC_RTCORBA_Factory::destroy_observer_strategy (TAO_EC_ObserverStrategy *x)
00176 {
00177   this->body_->destroy_observer_strategy (x);
00178 }
00179 
00180 TAO_EC_Scheduling_Strategy*
00181 TAO_EC_RTCORBA_Factory::create_scheduling_strategy (TAO_EC_Event_Channel_Base *ec)
00182 {
00183   return this->body_->create_scheduling_strategy (ec);
00184 }
00185 
00186 void
00187 TAO_EC_RTCORBA_Factory::destroy_scheduling_strategy (TAO_EC_Scheduling_Strategy* x)
00188 {
00189   this->body_->destroy_scheduling_strategy (x);
00190 }
00191 
00192 TAO_EC_ProxyPushConsumer_Collection*
00193 TAO_EC_RTCORBA_Factory::create_proxy_push_consumer_collection (TAO_EC_Event_Channel_Base *ec)
00194 {
00195   return this->body_->create_proxy_push_consumer_collection (ec);
00196 }
00197 
00198 void
00199 TAO_EC_RTCORBA_Factory::destroy_proxy_push_consumer_collection (TAO_EC_ProxyPushConsumer_Collection *x)
00200 {
00201   this->body_->destroy_proxy_push_consumer_collection (x);
00202 }
00203 
00204 TAO_EC_ProxyPushSupplier_Collection*
00205 TAO_EC_RTCORBA_Factory::create_proxy_push_supplier_collection (TAO_EC_Event_Channel_Base *ec)
00206 {
00207   return this->body_->create_proxy_push_supplier_collection (ec);
00208 }
00209 
00210 void
00211 TAO_EC_RTCORBA_Factory::destroy_proxy_push_supplier_collection (TAO_EC_ProxyPushSupplier_Collection *x)
00212 {
00213   this->body_->destroy_proxy_push_supplier_collection (x);
00214 }
00215 
00216 ACE_Lock*
00217 TAO_EC_RTCORBA_Factory::create_consumer_lock (void)
00218 {
00219   return this->body_->create_consumer_lock ();
00220 }
00221 
00222 void
00223 TAO_EC_RTCORBA_Factory::destroy_consumer_lock (ACE_Lock* x)
00224 {
00225   this->body_->destroy_consumer_lock (x);
00226 }
00227 
00228 ACE_Lock*
00229 TAO_EC_RTCORBA_Factory::create_supplier_lock (void)
00230 {
00231   return this->body_->create_supplier_lock ();
00232 }
00233 
00234 void
00235 TAO_EC_RTCORBA_Factory::destroy_supplier_lock (ACE_Lock* x)
00236 {
00237   this->body_->destroy_supplier_lock (x);
00238 }
00239 
00240 TAO_EC_ConsumerControl*
00241 TAO_EC_RTCORBA_Factory::create_consumer_control (TAO_EC_Event_Channel_Base* ec)
00242 {
00243   return this->body_->create_consumer_control (ec);
00244 }
00245 
00246 void
00247 TAO_EC_RTCORBA_Factory::destroy_consumer_control (TAO_EC_ConsumerControl* x)
00248 {
00249   this->body_->destroy_consumer_control (x);
00250 }
00251 
00252 TAO_EC_SupplierControl*
00253 TAO_EC_RTCORBA_Factory::create_supplier_control (TAO_EC_Event_Channel_Base* ec)
00254 {
00255   return this->body_->create_supplier_control (ec);
00256 }
00257 
00258 void
00259 TAO_EC_RTCORBA_Factory::destroy_supplier_control (TAO_EC_SupplierControl* x)
00260 {
00261   this->body_->destroy_supplier_control (x);
00262 }
00263 
00264 TAO_END_VERSIONED_NAMESPACE_DECL

Generated on Tue Feb 2 17:44:05 2010 for TAO_RTEvent by  doxygen 1.4.7