DomainC.cpp

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 //
00003 // DomainC.cpp,v 1.106 2006/06/27 06:22:13 jwillemsen Exp
00004 
00005 // ****  Code generated by the The ACE ORB (TAO) IDL Compiler ****
00006 // TAO and the TAO IDL Compiler have been developed by:
00007 //       Center for Distributed Object Computing
00008 //       Washington University
00009 //       St. Louis, MO
00010 //       USA
00011 //       http://www.cs.wustl.edu/~schmidt/doc-center.html
00012 // and
00013 //       Distributed Object Computing Laboratory
00014 //       University of California at Irvine
00015 //       Irvine, CA
00016 //       USA
00017 //       http://doc.ece.uci.edu/
00018 // and
00019 //       Institute for Software Integrated Systems
00020 //       Vanderbilt University
00021 //       Nashville, TN
00022 //       USA
00023 //       http://www.isis.vanderbilt.edu/
00024 //
00025 // Information about TAO is available at:
00026 //     http://www.cs.wustl.edu/~schmidt/TAO.html
00027 
00028 // TAO_IDL - Generated from
00029 // be\be_codegen.cpp:291
00030 
00031 
00032 #include "tao/DomainC.h"
00033 #include "tao/CDR.h"
00034 #include "tao/Invocation_Adapter.h"
00035 #include "tao/Object_T.h"
00036 #include "tao/Basic_Arguments.h"
00037 #include "tao/Object_Argument_T.h"
00038 #include "tao/Special_Basic_Arguments.h"
00039 #include "ace/OS_NS_string.h"
00040 
00041 #include "tao/ORB_Core.h"
00042 #include "tao/IFR_Client_Adapter.h"
00043 #include "tao/Any_Insert_Policy_T.h"
00044 #include "ace/Dynamic_Service.h"
00045 
00046 #if defined (__BORLANDC__)
00047 #pragma option -w-rvl -w-rch -w-ccc -w-aus -w-sig
00048 #endif /* __BORLANDC__ */
00049 
00050 #if !defined (__ACE_INLINE__)
00051 #include "tao/DomainC.inl"
00052 #endif /* !defined INLINE */
00053 
00054 // TAO_IDL - Generated from
00055 // be\be_visitor_arg_traits.cpp:70
00056 
00057 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00058 
00059 // TAO specific stuff.
00060 namespace CORBA
00061 {
00062   class InterfaceDef;
00063   typedef InterfaceDef *InterfaceDef_ptr;
00064   typedef TAO_Objref_Var_T<InterfaceDef> InterfaceDef_var;
00065   typedef TAO_Objref_Out_T<InterfaceDef> InterfaceDef_out;
00066 }
00067 
00068 namespace TAO
00069 {
00070 
00071 #if TAO_HAS_INTERCEPTORS == 1
00072 
00073 
00074 #endif /* TAO_HAS_INTERCEPTORS */
00075 
00076   template<>
00077   CORBA::Boolean
00078   In_Object_Argument_T<CORBA::InterfaceDef_ptr, TAO::Any_Insert_Policy_IFR_Client_Adapter <CORBA::InterfaceDef_ptr> >::marshal (TAO_OutputCDR &cdr)
00079   {
00080     TAO_IFR_Client_Adapter *adapter =
00081       ACE_Dynamic_Service<TAO_IFR_Client_Adapter>::instance (
00082           TAO_ORB_Core::ifr_client_adapter_name ()
00083         );
00084 
00085     return adapter->interfacedef_cdr_insert (cdr, this->x_);
00086   }
00087 }
00088 
00089 // Arg traits specializations.
00090 namespace TAO
00091 {
00092 
00093 #if !defined (_CORBA_POLICY__ARG_TRAITS_CS_)
00094 #define _CORBA_POLICY__ARG_TRAITS_CS_
00095 
00096   template<>
00097   class  Arg_Traits<CORBA::Policy>
00098     : public
00099         Object_Arg_Traits_T<
00100             CORBA::Policy_ptr,
00101             CORBA::Policy_var,
00102             CORBA::Policy_out,
00103             TAO::Objref_Traits<CORBA::Policy>,
00104             TAO::Any_Insert_Policy_AnyTypeCode_Adapter <CORBA::Policy_ptr>
00105           >
00106   {
00107   };
00108 
00109 #endif /* end #if !defined */
00110 
00111 #if !defined (_CORBA_INTERFACEDEF__ARG_TRAITS_CS_)
00112 #define _CORBA_INTERFACEDEF__ARG_TRAITS_CS_
00113 
00114   template<>
00115   class  Arg_Traits<CORBA::InterfaceDef>
00116     : public
00117         Object_Arg_Traits_T<
00118             CORBA::InterfaceDef_ptr,
00119             CORBA::InterfaceDef_var,
00120             CORBA::InterfaceDef_out,
00121             TAO::Objref_Traits<CORBA::InterfaceDef>,
00122             TAO::Any_Insert_Policy_IFR_Client_Adapter <CORBA::InterfaceDef_ptr>
00123           >
00124   {
00125   };
00126 
00127 #endif /* end #if !defined */
00128 }
00129 
00130 
00131 // TAO_IDL - Generated from
00132 // be\be_visitor_interface/interface_cs.cpp:60
00133 
00134 // Traits specializations for CORBA::DomainManager.
00135 
00136 CORBA::DomainManager_ptr
00137 TAO::Objref_Traits<CORBA::DomainManager>::duplicate (
00138     CORBA::DomainManager_ptr p
00139   )
00140 {
00141   return CORBA::DomainManager::_duplicate (p);
00142 }
00143 
00144 void
00145 TAO::Objref_Traits<CORBA::DomainManager>::release (
00146     CORBA::DomainManager_ptr p
00147   )
00148 {
00149   ::CORBA::release (p);
00150 }
00151 
00152 CORBA::DomainManager_ptr
00153 TAO::Objref_Traits<CORBA::DomainManager>::nil (void)
00154 {
00155   return CORBA::DomainManager::_nil ();
00156 }
00157 
00158 CORBA::Boolean
00159 TAO::Objref_Traits<CORBA::DomainManager>::marshal (
00160     const CORBA::DomainManager_ptr p,
00161     TAO_OutputCDR & cdr
00162   )
00163 {
00164   return CORBA::Object::marshal (p, cdr);
00165 }
00166 
00167 // Function pointer for collocation factory initialization.
00168 TAO::Collocation_Proxy_Broker *
00169 (*CORBA__TAO_DomainManager_Proxy_Broker_Factory_function_pointer) (
00170     CORBA::Object_ptr obj
00171   ) = 0;
00172 
00173 // TAO_IDL - Generated from
00174 // be\be_visitor_operation/operation_cs.cpp:78
00175 
00176 ::CORBA::Policy_ptr CORBA::DomainManager::get_domain_policy (
00177     ::CORBA::PolicyType policy_type
00178     ACE_ENV_ARG_DECL
00179   )
00180   ACE_THROW_SPEC ((
00181     CORBA::SystemException
00182   ))
00183 {
00184   if (!this->is_evaluated ())
00185     {
00186       ::CORBA::Object::tao_object_initialize (this);
00187     }
00188 
00189   if (this->the_TAO_DomainManager_Proxy_Broker_ == 0)
00190     {
00191       CORBA_DomainManager_setup_collocation ();
00192     }
00193 
00194   TAO::Arg_Traits< ::CORBA::Policy>::ret_val _tao_retval;
00195   TAO::Arg_Traits< ::CORBA::PolicyType>::in_arg_val _tao_policy_type (policy_type);
00196 
00197   TAO::Argument *_the_tao_operation_signature [] =
00198     {
00199       &_tao_retval,
00200       &_tao_policy_type
00201     };
00202 
00203   TAO::Invocation_Adapter _tao_call (
00204       this,
00205       _the_tao_operation_signature,
00206       2,
00207       "get_domain_policy",
00208       17,
00209       this->the_TAO_DomainManager_Proxy_Broker_
00210     );
00211 
00212   _tao_call.invoke (0, 0 ACE_ENV_ARG_PARAMETER);
00213   ACE_CHECK_RETURN (_tao_retval.excp ());
00214 
00215   return _tao_retval.retn ();
00216 }
00217 
00218 CORBA::DomainManager::DomainManager (void)
00219  : the_TAO_DomainManager_Proxy_Broker_ (0)
00220 {
00221   this->CORBA_DomainManager_setup_collocation ();
00222 }
00223 
00224 void
00225 CORBA::DomainManager::CORBA_DomainManager_setup_collocation ()
00226 {
00227   if (::CORBA__TAO_DomainManager_Proxy_Broker_Factory_function_pointer)
00228     {
00229       this->the_TAO_DomainManager_Proxy_Broker_ =
00230         ::CORBA__TAO_DomainManager_Proxy_Broker_Factory_function_pointer (this);
00231     }
00232 }
00233 
00234 CORBA::DomainManager::~DomainManager (void)
00235 {}
00236 
00237 void
00238 CORBA::DomainManager::_tao_any_destructor (void *_tao_void_pointer)
00239 {
00240   DomainManager *_tao_tmp_pointer =
00241     static_cast<DomainManager *> (_tao_void_pointer);
00242   ::CORBA::release (_tao_tmp_pointer);
00243 }
00244 
00245 CORBA::DomainManager_ptr
00246 CORBA::DomainManager::_narrow (
00247     CORBA::Object_ptr _tao_objref
00248     ACE_ENV_ARG_DECL
00249   )
00250 {
00251   return
00252     TAO::Narrow_Utils<DomainManager>::narrow (
00253         _tao_objref,
00254         "IDL:omg.org/CORBA/DomainManager:1.0",
00255         CORBA__TAO_DomainManager_Proxy_Broker_Factory_function_pointer
00256         ACE_ENV_ARG_PARAMETER
00257       );
00258 }
00259 
00260 CORBA::DomainManager_ptr
00261 CORBA::DomainManager::_unchecked_narrow (
00262     CORBA::Object_ptr _tao_objref
00263     ACE_ENV_ARG_DECL
00264   )
00265 {
00266   return
00267     TAO::Narrow_Utils<DomainManager>::unchecked_narrow (
00268         _tao_objref,
00269         "IDL:omg.org/CORBA/DomainManager:1.0",
00270         CORBA__TAO_DomainManager_Proxy_Broker_Factory_function_pointer
00271         ACE_ENV_ARG_PARAMETER
00272       );
00273 }
00274 
00275 CORBA::DomainManager_ptr
00276 CORBA::DomainManager::_duplicate (DomainManager_ptr obj)
00277 {
00278   if (! ::CORBA::is_nil (obj))
00279     {
00280       obj->_add_ref ();
00281     }
00282 
00283   return obj;
00284 }
00285 
00286 void
00287 CORBA::DomainManager::_tao_release (DomainManager_ptr obj)
00288 {
00289   ::CORBA::release (obj);
00290 }
00291 
00292 CORBA::Boolean
00293 CORBA::DomainManager::_is_a (
00294     const char *value
00295     ACE_ENV_ARG_DECL
00296   )
00297 {
00298   if (
00299       !ACE_OS::strcmp (
00300           value,
00301           "IDL:omg.org/CORBA/DomainManager:1.0"
00302         ) ||
00303       !ACE_OS::strcmp (
00304           value,
00305           "IDL:omg.org/CORBA/Object:1.0"
00306         )
00307     )
00308     {
00309       return true; // success using local knowledge
00310     }
00311   else
00312     {
00313       return this->::CORBA::Object::_is_a (
00314           value
00315           ACE_ENV_ARG_PARAMETER
00316         );
00317     }
00318 }
00319 
00320 const char* CORBA::DomainManager::_interface_repository_id (void) const
00321 {
00322   return "IDL:omg.org/CORBA/DomainManager:1.0";
00323 }
00324 
00325 CORBA::Boolean
00326 CORBA::DomainManager::marshal (TAO_OutputCDR &cdr)
00327 {
00328   return (cdr << this);
00329 }
00330 
00331 // TAO_IDL - Generated from
00332 // be\be_visitor_interface/interface_cs.cpp:60
00333 
00334 // Traits specializations for CORBA::ConstructionPolicy.
00335 
00336 CORBA::ConstructionPolicy_ptr
00337 TAO::Objref_Traits<CORBA::ConstructionPolicy>::duplicate (
00338     CORBA::ConstructionPolicy_ptr p
00339   )
00340 {
00341   return CORBA::ConstructionPolicy::_duplicate (p);
00342 }
00343 
00344 void
00345 TAO::Objref_Traits<CORBA::ConstructionPolicy>::release (
00346     CORBA::ConstructionPolicy_ptr p
00347   )
00348 {
00349   ::CORBA::release (p);
00350 }
00351 
00352 CORBA::ConstructionPolicy_ptr
00353 TAO::Objref_Traits<CORBA::ConstructionPolicy>::nil (void)
00354 {
00355   return CORBA::ConstructionPolicy::_nil ();
00356 }
00357 
00358 CORBA::Boolean
00359 TAO::Objref_Traits<CORBA::ConstructionPolicy>::marshal (
00360     const CORBA::ConstructionPolicy_ptr p,
00361     TAO_OutputCDR & cdr
00362   )
00363 {
00364   return CORBA::Object::marshal (p, cdr);
00365 }
00366 
00367 // Function pointer for collocation factory initialization.
00368 TAO::Collocation_Proxy_Broker *
00369 (*CORBA__TAO_ConstructionPolicy_Proxy_Broker_Factory_function_pointer) (
00370     CORBA::Object_ptr obj
00371   ) = 0;
00372 
00373 // TAO_IDL - Generated from
00374 // be\be_visitor_operation/operation_cs.cpp:78
00375 
00376 void CORBA::ConstructionPolicy::make_domain_manager (
00377     ::CORBA::InterfaceDef_ptr object_type,
00378     ::CORBA::Boolean constr_policy
00379     ACE_ENV_ARG_DECL
00380   )
00381   ACE_THROW_SPEC ((
00382     CORBA::SystemException
00383   ))
00384 {
00385   if (!this->is_evaluated ())
00386     {
00387       ::CORBA::Object::tao_object_initialize (this);
00388     }
00389 
00390   if (this->the_TAO_ConstructionPolicy_Proxy_Broker_ == 0)
00391     {
00392       CORBA_ConstructionPolicy_setup_collocation ();
00393     }
00394 
00395   TAO::Arg_Traits< void>::ret_val _tao_retval;
00396   TAO::Arg_Traits< ::CORBA::InterfaceDef>::in_arg_val _tao_object_type (object_type);
00397   TAO::Arg_Traits< ::ACE_InputCDR::to_boolean>::in_arg_val _tao_constr_policy (constr_policy);
00398 
00399   TAO::Argument *_the_tao_operation_signature [] =
00400     {
00401       &_tao_retval,
00402       &_tao_object_type,
00403       &_tao_constr_policy
00404     };
00405 
00406   TAO::Invocation_Adapter _tao_call (
00407       this,
00408       _the_tao_operation_signature,
00409       3,
00410       "make_domain_manager",
00411       19,
00412       this->the_TAO_ConstructionPolicy_Proxy_Broker_
00413     );
00414 
00415   _tao_call.invoke (0, 0 ACE_ENV_ARG_PARAMETER);
00416   ACE_CHECK;
00417 }
00418 
00419 CORBA::ConstructionPolicy::ConstructionPolicy (void)
00420  : the_TAO_ConstructionPolicy_Proxy_Broker_ (0)
00421 {
00422   this->CORBA_ConstructionPolicy_setup_collocation ();
00423 }
00424 
00425 void
00426 CORBA::ConstructionPolicy::CORBA_ConstructionPolicy_setup_collocation ()
00427 {
00428   if (::CORBA__TAO_ConstructionPolicy_Proxy_Broker_Factory_function_pointer)
00429     {
00430       this->the_TAO_ConstructionPolicy_Proxy_Broker_ =
00431         ::CORBA__TAO_ConstructionPolicy_Proxy_Broker_Factory_function_pointer (this);
00432     }
00433 
00434   this->CORBA_Policy_setup_collocation ();
00435 }
00436 
00437 CORBA::ConstructionPolicy::~ConstructionPolicy (void)
00438 {}
00439 
00440 void
00441 CORBA::ConstructionPolicy::_tao_any_destructor (void *_tao_void_pointer)
00442 {
00443   ConstructionPolicy *_tao_tmp_pointer =
00444     static_cast<ConstructionPolicy *> (_tao_void_pointer);
00445   ::CORBA::release (_tao_tmp_pointer);
00446 }
00447 
00448 CORBA::ConstructionPolicy_ptr
00449 CORBA::ConstructionPolicy::_narrow (
00450     CORBA::Object_ptr _tao_objref
00451     ACE_ENV_ARG_DECL
00452   )
00453 {
00454   return
00455     TAO::Narrow_Utils<ConstructionPolicy>::narrow (
00456         _tao_objref,
00457         "IDL:omg.org/CORBA/ConstructionPolicy:1.0",
00458         CORBA__TAO_ConstructionPolicy_Proxy_Broker_Factory_function_pointer
00459         ACE_ENV_ARG_PARAMETER
00460       );
00461 }
00462 
00463 CORBA::ConstructionPolicy_ptr
00464 CORBA::ConstructionPolicy::_unchecked_narrow (
00465     CORBA::Object_ptr _tao_objref
00466     ACE_ENV_ARG_DECL
00467   )
00468 {
00469   return
00470     TAO::Narrow_Utils<ConstructionPolicy>::unchecked_narrow (
00471         _tao_objref,
00472         "IDL:omg.org/CORBA/ConstructionPolicy:1.0",
00473         CORBA__TAO_ConstructionPolicy_Proxy_Broker_Factory_function_pointer
00474         ACE_ENV_ARG_PARAMETER
00475       );
00476 }
00477 
00478 CORBA::ConstructionPolicy_ptr
00479 CORBA::ConstructionPolicy::_duplicate (ConstructionPolicy_ptr obj)
00480 {
00481   if (! ::CORBA::is_nil (obj))
00482     {
00483       obj->_add_ref ();
00484     }
00485 
00486   return obj;
00487 }
00488 
00489 void
00490 CORBA::ConstructionPolicy::_tao_release (ConstructionPolicy_ptr obj)
00491 {
00492   ::CORBA::release (obj);
00493 }
00494 
00495 CORBA::Boolean
00496 CORBA::ConstructionPolicy::_is_a (
00497     const char *value
00498     ACE_ENV_ARG_DECL
00499   )
00500 {
00501   if (
00502       !ACE_OS::strcmp (
00503           value,
00504           "IDL:omg.org/CORBA/Policy:1.0"
00505         ) ||
00506       !ACE_OS::strcmp (
00507           value,
00508           "IDL:omg.org/CORBA/ConstructionPolicy:1.0"
00509         ) ||
00510       !ACE_OS::strcmp (
00511           value,
00512           "IDL:omg.org/CORBA/Object:1.0"
00513         )
00514     )
00515     {
00516       return true; // success using local knowledge
00517     }
00518   else
00519     {
00520       return this->::CORBA::Object::_is_a (
00521           value
00522           ACE_ENV_ARG_PARAMETER
00523         );
00524     }
00525 }
00526 
00527 const char* CORBA::ConstructionPolicy::_interface_repository_id (void) const
00528 {
00529   return "IDL:omg.org/CORBA/ConstructionPolicy:1.0";
00530 }
00531 
00532 CORBA::Boolean
00533 CORBA::ConstructionPolicy::marshal (TAO_OutputCDR &cdr)
00534 {
00535   return (cdr << this);
00536 }
00537 
00538 // TAO_IDL - Generated from
00539 // be\be_visitor_sequence/sequence_cs.cpp:65
00540 
00541 #if !defined (_CORBA_DOMAINMANAGERLIST_CS_)
00542 #define _CORBA_DOMAINMANAGERLIST_CS_
00543 
00544 CORBA::DomainManagerList::DomainManagerList (void)
00545 {}
00546 
00547 CORBA::DomainManagerList::DomainManagerList (
00548     CORBA::ULong max
00549   )
00550   : TAO::unbounded_object_reference_sequence<
00551         CORBA::DomainManager, CORBA::DomainManager_var
00552       >
00553     (max)
00554 {}
00555 
00556 CORBA::DomainManagerList::DomainManagerList (
00557     CORBA::ULong max,
00558     CORBA::ULong length,
00559     CORBA::DomainManager_ptr * buffer,
00560     CORBA::Boolean release
00561   )
00562   : TAO::unbounded_object_reference_sequence<
00563         CORBA::DomainManager, CORBA::DomainManager_var
00564       >
00565     (max, length, buffer, release)
00566 {}
00567 
00568 CORBA::DomainManagerList::DomainManagerList (
00569     const DomainManagerList &seq
00570   )
00571   : TAO::unbounded_object_reference_sequence<
00572         CORBA::DomainManager, CORBA::DomainManager_var
00573       >
00574     (seq)
00575 {}
00576 
00577 CORBA::DomainManagerList::~DomainManagerList (void)
00578 {}
00579 
00580 void CORBA::DomainManagerList::_tao_any_destructor (
00581     void * _tao_void_pointer
00582   )
00583 {
00584   DomainManagerList * _tao_tmp_pointer =
00585     static_cast<DomainManagerList *> (_tao_void_pointer);
00586   delete _tao_tmp_pointer;
00587 }
00588 
00589 #endif /* end #if !defined */
00590 
00591 // TAO_IDL - Generated from
00592 // be\be_visitor_interface/cdr_op_cs.cpp:63
00593 
00594 CORBA::Boolean operator<< (
00595     TAO_OutputCDR &strm,
00596     const CORBA::DomainManager_ptr _tao_objref
00597   )
00598 {
00599   CORBA::Object_ptr _tao_corba_obj = _tao_objref;
00600   return (strm << _tao_corba_obj);
00601 }
00602 
00603 CORBA::Boolean operator>> (
00604     TAO_InputCDR &strm,
00605     CORBA::DomainManager_ptr &_tao_objref
00606   )
00607 {
00608   CORBA::Object_var obj;
00609 
00610   if (!(strm >> obj.inout ()))
00611     {
00612       return false;
00613     }
00614 
00615   typedef ::CORBA::DomainManager RHS_SCOPED_NAME;
00616 
00617   // Narrow to the right type.
00618   _tao_objref =
00619     TAO::Narrow_Utils<RHS_SCOPED_NAME>::unchecked_narrow (
00620         obj.in (),
00621         CORBA__TAO_DomainManager_Proxy_Broker_Factory_function_pointer
00622       );
00623 
00624   return 1;
00625 }
00626 
00627 // TAO_IDL - Generated from
00628 // be\be_visitor_interface/cdr_op_cs.cpp:63
00629 
00630 CORBA::Boolean operator<< (
00631     TAO_OutputCDR &strm,
00632     const CORBA::ConstructionPolicy_ptr _tao_objref
00633   )
00634 {
00635   CORBA::Object_ptr _tao_corba_obj = _tao_objref;
00636   return (strm << _tao_corba_obj);
00637 }
00638 
00639 CORBA::Boolean operator>> (
00640     TAO_InputCDR &strm,
00641     CORBA::ConstructionPolicy_ptr &_tao_objref
00642   )
00643 {
00644   CORBA::Object_var obj;
00645 
00646   if (!(strm >> obj.inout ()))
00647     {
00648       return false;
00649     }
00650 
00651   typedef ::CORBA::ConstructionPolicy RHS_SCOPED_NAME;
00652 
00653   // Narrow to the right type.
00654   _tao_objref =
00655     TAO::Narrow_Utils<RHS_SCOPED_NAME>::unchecked_narrow (
00656         obj.in (),
00657         CORBA__TAO_ConstructionPolicy_Proxy_Broker_Factory_function_pointer
00658       );
00659 
00660   return 1;
00661 }
00662 
00663 // TAO_IDL - Generated from
00664 // be\be_visitor_sequence/cdr_op_cs.cpp:96
00665 
00666 #if !defined _TAO_CDR_OP_CORBA_DomainManagerList_CPP_
00667 #define _TAO_CDR_OP_CORBA_DomainManagerList_CPP_
00668 
00669 CORBA::Boolean operator<< (
00670     TAO_OutputCDR &strm,
00671     const CORBA::DomainManagerList &_tao_sequence
00672   )
00673 {
00674   return TAO::marshal_sequence(strm, _tao_sequence);
00675 }
00676 
00677 CORBA::Boolean operator>> (
00678     TAO_InputCDR &strm,
00679     CORBA::DomainManagerList &_tao_sequence
00680   )
00681 {
00682   return TAO::demarshal_sequence(strm, _tao_sequence);
00683 }
00684 
00685 #endif /* _TAO_CDR_OP_CORBA_DomainManagerList_CPP_ */
00686 
00687 TAO_END_VERSIONED_NAMESPACE_DECL

Generated on Thu Nov 9 11:54:10 2006 for TAO by doxygen 1.3.6