Merge pull request #2309 from mitza-oci/warnings
[ACE_TAO.git] / TAO / tao / WrongTransactionC.cpp
blob614703f33dbf9a7143c56aada0aabd5d58b1e6e0
1 // -*- C++ -*-
2 // **** Code generated by the The ACE ORB (TAO) IDL Compiler ****
3 // TAO and the TAO IDL Compiler have been developed by:
4 // Center for Distributed Object Computing
5 // Washington University
6 // St. Louis, MO
7 // USA
8 // http://www.cs.wustl.edu/~schmidt/doc-center.html
9 // and
10 // Distributed Object Computing Laboratory
11 // University of California at Irvine
12 // Irvine, CA
13 // USA
14 // http://doc.ece.uci.edu/
15 // and
16 // Institute for Software Integrated Systems
17 // Vanderbilt University
18 // Nashville, TN
19 // USA
20 // http://www.isis.vanderbilt.edu/
22 // Information about TAO is available at:
23 // http://www.dre.vanderbilt.edu/~schmidt/TAO.html
25 // TAO_IDL - Generated from
26 // be\be_codegen.cpp:291
29 #include "tao/WrongTransactionC.h"
30 #include "tao/CDR.h"
31 #include "tao/SystemException.h"
32 #include "ace/OS_NS_string.h"
33 #include "tao/AnyTypeCode_Adapter.h"
34 #include "ace/Dynamic_Service.h"
35 #include "ace/Log_Msg.h"
37 // TAO_IDL - Generated from
38 // be\be_visitor_arg_traits.cpp:70
40 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
42 // Arg traits specializations.
43 namespace TAO
48 // TAO_IDL - Generated from
49 // be\be_visitor_exception/exception_cs.cpp:63
51 CORBA::WrongTransaction::WrongTransaction ()
52 : CORBA::UserException (
53 "IDL:omg.org/CORBA/WrongTransaction:1.0",
54 "WrongTransaction"
59 CORBA::WrongTransaction::~WrongTransaction ()
63 CORBA::WrongTransaction::WrongTransaction (const ::CORBA::WrongTransaction &_tao_excp)
64 : CORBA::UserException (
65 _tao_excp._rep_id (),
66 _tao_excp._name ()
71 CORBA::WrongTransaction&
72 CORBA::WrongTransaction::operator= (const ::CORBA::WrongTransaction &_tao_excp)
74 this->::CORBA::UserException::operator= (_tao_excp);
75 return *this;
78 void CORBA::WrongTransaction::_tao_any_destructor (void *_tao_void_pointer)
80 WrongTransaction *_tao_tmp_pointer =
81 static_cast<WrongTransaction *> (_tao_void_pointer);
82 delete _tao_tmp_pointer;
85 CORBA::WrongTransaction *
86 CORBA::WrongTransaction::_downcast (CORBA::Exception *_tao_excp)
88 return dynamic_cast<WrongTransaction *> (_tao_excp);
91 const CORBA::WrongTransaction *
92 CORBA::WrongTransaction::_downcast (CORBA::Exception const *_tao_excp)
94 return dynamic_cast<const WrongTransaction *> (_tao_excp);
97 CORBA::Exception *CORBA::WrongTransaction::_alloc ()
99 CORBA::Exception *retval = nullptr;
100 ACE_NEW_RETURN (retval, ::CORBA::WrongTransaction, nullptr);
101 return retval;
104 CORBA::Exception *
105 CORBA::WrongTransaction::_tao_duplicate () const
107 CORBA::Exception *result = nullptr;
108 ACE_NEW_RETURN (
109 result,
110 ::CORBA::WrongTransaction (*this),
111 nullptr
113 return result;
116 void CORBA::WrongTransaction::_raise () const
118 throw *this;
121 void CORBA::WrongTransaction::_tao_encode (
122 TAO_OutputCDR &cdr) const
124 if (cdr << *this)
126 return;
129 throw ::CORBA::MARSHAL ();
132 void CORBA::WrongTransaction::_tao_decode (
133 TAO_InputCDR &cdr
136 if (cdr >> *this)
138 return;
141 throw ::CORBA::MARSHAL ();
144 // TAO extension - the virtual _type method.
145 CORBA::TypeCode_ptr CORBA::WrongTransaction::_tao_type () const
147 TAO_AnyTypeCode_Adapter *adapter =
148 ACE_Dynamic_Service<TAO_AnyTypeCode_Adapter>::instance (
149 "AnyTypeCode_Adapter"
151 if (adapter != nullptr)
152 return adapter->_tao_type_WrongTransaction ();
153 else
155 TAOLIB_ERROR ((LM_ERROR,
156 ACE_TEXT ("(%P|%t) %p\n"),
157 ACE_TEXT ("Unable to find the ")
158 ACE_TEXT ("AnyTypeCode Adapter instance")));
159 return nullptr;
163 // TAO_IDL - Generated from
164 // be\be_visitor_exception/cdr_op_cs.cpp:60
166 CORBA::Boolean operator<< (
167 TAO_OutputCDR &strm,
168 const CORBA::WrongTransaction &_tao_aggregate
171 // Marshal the repository ID.
172 return (strm << _tao_aggregate._rep_id ());
175 CORBA::Boolean operator>> (
176 TAO_InputCDR &,
177 CORBA::WrongTransaction&
180 return true;
183 TAO_END_VERSIONED_NAMESPACE_DECL