diff options
author | bala <balanatarajan@users.noreply.github.com> | 2003-08-29 16:52:15 +0000 |
---|---|---|
committer | bala <balanatarajan@users.noreply.github.com> | 2003-08-29 16:52:15 +0000 |
commit | e1793d558417dc28adc99c944b090cf720b5b2e3 (patch) | |
tree | 8b3a2d8e81aa43a6ffc1741560bb0a86a4ebe320 | |
parent | f61a34ee607e223f9b6581db289a1f054b05bb2f (diff) | |
download | ATCD-e1793d558417dc28adc99c944b090cf720b5b2e3.tar.gz |
*** empty log message ***
-rw-r--r-- | TAO/tests/Bench/wire/testC.cpp | 526 |
1 files changed, 0 insertions, 526 deletions
diff --git a/TAO/tests/Bench/wire/testC.cpp b/TAO/tests/Bench/wire/testC.cpp deleted file mode 100644 index 75cf14a3935..00000000000 --- a/TAO/tests/Bench/wire/testC.cpp +++ /dev/null @@ -1,526 +0,0 @@ -// -*- C++ -*- -// -// $Id$ - -// **** Code generated by the The ACE ORB (TAO) IDL Compiler **** -// TAO and the TAO IDL Compiler have been developed by: -// Center for Distributed Object Computing -// Washington University -// St. Louis, MO -// USA -// http://www.cs.wustl.edu/~schmidt/doc-center.html -// and -// Distributed Object Computing Laboratory -// University of California at Irvine -// Irvine, CA -// USA -// http://doc.ece.uci.edu/ -// and -// Institute for Software Integrated Systems -// Vanderbilt University -// Nashville, TN -// USA -// http://www.isis.vanderbilt.edu/ -// -// Information about TAO is available at: -// http://www.cs.wustl.edu/~schmidt/TAO.html - -// TAO_IDL - Generated from -// be/be_codegen.cpp:301 - - -#include "testC.h" -#include "tao/Stub.h" -#include "tao/Invocation_Adapter.h" -#include "tao/Invocation.h" -#include "tao/PortableInterceptor.h" - -#if TAO_HAS_INTERCEPTORS == 1 -#include "tao/RequestInfo_Util.h" -#include "tao/ClientRequestInfo_i.h" -#include "tao/ClientInterceptorAdapter.h" -#endif /* TAO_HAS_INTERCEPTORS == 1 */ - -#include "tao/Any_Impl_T.h" -#include "tao/Any_Basic_Impl_T.h" -#include "tao/Any_Special_Basic_Impl_T.h" -#include "tao/Any_Dual_Impl_T.h" -#include "tao/Any_Special_Impl_T.h" -#include "tao/Any_Array_Impl_T.h" - -#if defined (__BORLANDC__) -#pragma option -w-rvl -w-rch -w-ccc -w-aus -w-sig -#endif /* __BORLANDC__ */ - -#if !defined (__ACE_INLINE__) -#include "testC.i" -#endif /* !defined INLINE */ - -// TAO_IDL - Generated from -// be/be_visitor_interface/interface_cs.cpp:60 - -// Traits specializations for foo. - -foo_ptr -TAO::Objref_Traits<foo>::tao_duplicate ( - foo_ptr p - ) -{ - return foo::_duplicate (p); -} - -void -TAO::Objref_Traits<foo>::tao_release ( - foo_ptr p - ) -{ - CORBA::release (p); -} - -foo_ptr -TAO::Objref_Traits<foo>::tao_nil (void) -{ - return foo::_nil (); -} - -CORBA::Boolean -TAO::Objref_Traits<foo>::tao_marshal ( - foo_ptr p, - TAO_OutputCDR & cdr - ) -{ - return p->marshal (cdr); -} - -int foo::_tao_class_id = 0; - -// Function pointer for collocation factory initialization. -TAO::Collocation_Proxy_Broker * -(*_TAO_foo_Proxy_Broker_Factory_function_pointer) ( - CORBA::Object_ptr obj - ) = 0; - -// TAO_IDL - Generated from -// be/be_visitor_operation/operation_cs.cpp:80 - -char * foo::all_str ( - const char * inarg, - char *& inoutarg, - CORBA::String_out outarg - ACE_ENV_ARG_DECL - ) - ACE_THROW_SPEC (( - CORBA::SystemException - )) -{ - if (!this->is_evaluated ()) - { - ACE_NESTED_CLASS (CORBA, Object)::tao_object_initialize (this); - } - - if (this->the_TAO_foo_Proxy_Broker_ == 0) - { - foo_setup_collocation ( - this->ACE_NESTED_CLASS (CORBA, Object)::_is_collocated () - ); - } - - TAO::Arg_Traits<CORBA::Char *>::stub_ret_val _tao_retval; - TAO::Arg_Traits<CORBA::Char *>::in_arg_val _tao_inarg (inarg); - TAO::Arg_Traits<CORBA::Char *>::inout_arg_val _tao_inoutarg (inoutarg); - TAO::Arg_Traits<CORBA::Char *>::out_arg_val _tao_outarg (outarg); - - TAO::Argument *_tao_signature [] = - { - &_tao_retval, - &_tao_inarg, - &_tao_inoutarg, - &_tao_outarg - }; - - TAO::Invocation_Adapter _tao_call ( - this, - _tao_signature, - 4, - "all_str", - 7, - this->the_TAO_foo_Proxy_Broker_ - ); - - _tao_call.invoke (0, 0 ACE_ENV_ARG_PARAMETER); - ACE_CHECK_RETURN (_tao_retval.excp ()); - - return _tao_retval.retn (); -} - -foo::foo (int collocated) - : the_TAO_foo_Proxy_Broker_ (0) -{ - this->foo_setup_collocation (collocated); -} - -void -foo::foo_setup_collocation (int collocated) -{ - if (collocated) - this->the_TAO_foo_Proxy_Broker_ = - ::_TAO_foo_Proxy_Broker_Factory_function_pointer (this); -} - -foo::~foo (void) -{} - -void -foo::_tao_any_destructor (void *_tao_void_pointer) -{ - foo *tmp = ACE_static_cast (foo *, _tao_void_pointer); - CORBA::release (tmp); -} - -foo_ptr -foo::_narrow ( - CORBA::Object_ptr obj - ACE_ENV_ARG_DECL - ) -{ - if (CORBA::is_nil (obj)) - { - return foo::_nil (); - } - - if (! obj->_is_local ()) - { - CORBA::Boolean is_a = - obj->_is_a ( - "IDL:foo:1.0" - ACE_ENV_ARG_PARAMETER - ); - ACE_CHECK_RETURN (foo::_nil ()); - - if (is_a == 0) - { - return foo::_nil (); - } - } - - return foo::_unchecked_narrow (obj ACE_ENV_ARG_PARAMETER); -} - -foo_ptr -foo::_unchecked_narrow ( - CORBA::Object_ptr obj - ACE_ENV_ARG_DECL_NOT_USED - ) -{ - if (CORBA::is_nil (obj)) - { - return foo::_nil (); - } - - foo_ptr default_proxy = foo::_nil (); - - // Code for lazily evaluated IOR's - if (!obj->is_evaluated ()) - { - ACE_NEW_RETURN ( - default_proxy, - ::foo ( - obj->steal_ior (), - obj->orb_core () - ), - foo::_nil () - ); - - return default_proxy; - } - - if (! obj->_is_local ()) - { - TAO_Stub* stub = obj->_stubobj (); - - if (stub != 0) - { - stub->_incr_refcnt (); - } - - if ( - !CORBA::is_nil (stub->servant_orb_var ().ptr ()) && - stub->servant_orb_var ()->orb_core ()->optimize_collocation_objects () && - obj->_is_collocated () && - _TAO_foo_Proxy_Broker_Factory_function_pointer != 0 - ) - { - ACE_NEW_RETURN ( - default_proxy, - ::foo ( - stub, - 1, - obj->_servant () - ), - foo::_nil () - ); - } - - if (CORBA::is_nil (default_proxy)) - { - ACE_NEW_RETURN ( - default_proxy, - ::foo ( - stub, - 0, - obj->_servant () - ), - foo::_nil () - ); - } - - return default_proxy; - } - else - { - foo_ptr p = - dynamic_cast <foo_ptr> (obj); - - p->_add_ref (); - - return p; - } - -} - -foo_ptr -foo::_duplicate (foo_ptr obj) -{ - if (! CORBA::is_nil (obj)) - { - obj->_add_ref (); - } - - return obj; -} - -CORBA::Boolean -foo::_is_a ( - const char *value - ACE_ENV_ARG_DECL - ) -{ - if ( - !ACE_OS::strcmp ( - (char *)value, - "IDL:foo:1.0" - ) || - !ACE_OS::strcmp ( - (char *)value, - "IDL:omg.org/CORBA/Object:1.0" - ) - ) - { - return 1; // success using local knowledge - } - else - { - return this->ACE_NESTED_CLASS (CORBA, Object)::_is_a ( - value - ACE_ENV_ARG_PARAMETER - ); - } -} - -void *foo::_tao_QueryInterface (ptrdiff_t type) -{ - void *retv = 0; - - if (type == ACE_reinterpret_cast ( - ptrdiff_t, - &foo::_tao_class_id) - ) - { - retv = ACE_reinterpret_cast (void*, this); - } - else if (type == ACE_reinterpret_cast ( - ptrdiff_t, - &CORBA::Object::_tao_class_id) - ) - { - retv = - ACE_reinterpret_cast ( - void *, - ACE_static_cast (CORBA::Object_ptr, this) - ); - } - - if (retv != 0) - { - this->_add_ref (); - } - - return retv; -} - -const char* foo::_interface_repository_id (void) const -{ - return "IDL:foo:1.0"; -} - -CORBA::Boolean -foo::marshal (TAO_OutputCDR &cdr) -{ - return (cdr << this); -} - -// TAO_IDL - Generated from -// be/be_visitor_typecode/typecode_defn.cpp:284 - -static const CORBA::Long _oc_foo[] = -{ - TAO_ENCAP_BYTE_ORDER, // byte order - 12, - ACE_NTOHL (0x49444c3a), - ACE_NTOHL (0x666f6f3a), - ACE_NTOHL (0x312e3000), // repository ID = IDL:foo:1.0 - 4, - ACE_NTOHL (0x666f6f00), // name = foo - }; - -static CORBA::TypeCode _tc_TAO_tc_foo ( - CORBA::tk_objref, - sizeof (_oc_foo), - (char *) &_oc_foo, - 0, - sizeof (foo) - ); - -::CORBA::TypeCode_ptr _tc_foo = - &_tc_TAO_tc_foo; - -// TAO_IDL - Generated from -// be/be_visitor_interface/any_op_cs.cpp:50 - -// Copying insertion. -void -operator<<= ( - CORBA::Any &_tao_any, - foo_ptr _tao_elem - ) -{ - foo_ptr _tao_objptr = - foo::_duplicate (_tao_elem); - _tao_any <<= &_tao_objptr; -} - -// Non-copying insertion. -void -operator<<= ( - CORBA::Any &_tao_any, - foo_ptr *_tao_elem - ) -{ - TAO::Any_Impl_T<foo>::insert ( - _tao_any, - foo::_tao_any_destructor, - _tc_foo, - *_tao_elem - ); -} - -CORBA::Boolean -operator>>= ( - const CORBA::Any &_tao_any, - foo_ptr &_tao_elem - ) -{ - return - TAO::Any_Impl_T<foo>::extract ( - _tao_any, - foo::_tao_any_destructor, - _tc_foo, - _tao_elem - ); -} - -// TAO_IDL - Generated from -// be/be_visitor_interface/cdr_op_cs.cpp:63 - -CORBA::Boolean operator<< ( - TAO_OutputCDR &strm, - const foo_ptr _tao_objref - ) -{ - CORBA::Object_ptr _tao_corba_obj = _tao_objref; - return (strm << _tao_corba_obj); -} - -CORBA::Boolean operator>> ( - TAO_InputCDR &strm, - foo_ptr &_tao_objref - ) -{ - ACE_TRY_NEW_ENV - { - CORBA::Object_var obj; - - if ((strm >> obj.inout ()) == 0) - { - return 0; - } - - // Narrow to the right type. - _tao_objref = - foo::_unchecked_narrow ( - obj.in () - ACE_ENV_ARG_PARAMETER - ); - ACE_TRY_CHECK; - return 1; - } - ACE_CATCHANY - { - // do nothing - } - ACE_ENDTRY; - return 0; -} - -// TAO_IDL - Generated from -// be/be_visitor_root/root.cpp:1650 - -#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) - - template class - TAO_Objref_Var_T< - foo, - TAO::Objref_Traits<foo> - >; - - template class - TAO_Objref_Out_T< - foo, - TAO::Objref_Traits<foo> - >; - - template class - TAO::Any_Impl_T< - foo - >; - -#elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA) - -# pragma instantiate \ - TAO_Objref_Var_T< \ - foo, \ - TAO::Objref_Traits<foo> \ - > - -# pragma instantiate \ - TAO_Objref_Out_T< \ - foo, \ - TAO::Objref_Traits<foo> \ - > - -# pragma instantiate \ - TAO::Any_Impl_T< \ - foo \ - > - -#endif /* !ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ |