CORBA::UnknownUserException Class Reference

UnknownUserException. More...

#include <Unknown_User_Exception.h>

Inheritance diagram for CORBA::UnknownUserException:

Inheritance graph
[legend]
Collaboration diagram for CORBA::UnknownUserException:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 UnknownUserException (void)
 Constructor.
 UnknownUserException (CORBA::Any &exception)
 Constructor.
 UnknownUserException (const UnknownUserException &e)
 Copy constructor.
virtual ~UnknownUserException (void)
 Destructor.
virtual void _raise (void) const
 To throw an UnknownUserException of this type.
virtual CORBA::Exception_tao_duplicate (void) const
virtual void _tao_encode (TAO_OutputCDR &cdr) const
virtual void _tao_decode (TAO_InputCDR &cdr)
virtual const char * _rep_id (void) const
 Return the repository ID of the Exception.
virtual CORBA::TypeCode_ptr _tao_type (void) const
 This class has a specific typecode.

Static Public Member Functions

static UnknownUserException_downcast (CORBA::Exception *ex)
 Narrow to an UnknowUserException.
static UnknownUserException
const * 
_downcast (CORBA::Exception const *ex)

Public Attributes

CORBA::Any &exception void
 Return the any containing the user exception.

Private Attributes

CORBA::Any * exception_
 Holder for the actual exception.

Detailed Description

UnknownUserException.

When user exceptions are received by a DII invocation the ORB is unable to create the exception with the right dynamic type; to workaround this problem it throws a CORBA::UnknownUserException that contains the exception inside an Any.

Definition at line 58 of file Unknown_User_Exception.h.


Constructor & Destructor Documentation

TAO_BEGIN_VERSIONED_NAMESPACE_DECL CORBA::UnknownUserException::UnknownUserException ( void   ) 

Constructor.

Definition at line 21 of file Unknown_User_Exception.cpp.

00022   : CORBA::UserException ("IDL:omg.org/CORBA/UnknownUserException:1.0",
00023                           "UnknownUserException"),
00024     exception_ (0)
00025 {
00026 }

CORBA::UnknownUserException::UnknownUserException ( CORBA::Any &  exception  ) 

Constructor.

Definition at line 28 of file Unknown_User_Exception.cpp.

References ACE_NEW.

00029   : CORBA::UserException ("IDL:omg.org/CORBA/UnknownUserException:1.0",
00030                          "UnknownUserException")
00031 {
00032   ACE_NEW (this->exception_,
00033            CORBA::Any (ex));
00034 }

CORBA::UnknownUserException::UnknownUserException ( const UnknownUserException e  ) 

Copy constructor.

Definition at line 36 of file Unknown_User_Exception.cpp.

References ACE_NEW, and exception_.

00039   : CORBA::UserException (e._rep_id (),
00040                          e._name ())
00041 {
00042   ACE_NEW (this->exception_,
00043            CORBA::Any (*e.exception_));
00044 }

CORBA::UnknownUserException::~UnknownUserException ( void   )  [virtual]

Destructor.

Definition at line 46 of file Unknown_User_Exception.cpp.

References exception_.

00047 {
00048   delete this->exception_;
00049 }


Member Function Documentation

CORBA::UnknownUserException const * CORBA::UnknownUserException::_downcast ( CORBA::Exception const *  ex  )  [static]

Reimplemented from CORBA::UserException.

Definition at line 64 of file Unknown_User_Exception.cpp.

00065 {
00066   return dynamic_cast<CORBA::UnknownUserException const *> (ex);
00067 }

CORBA::UnknownUserException * CORBA::UnknownUserException::_downcast ( CORBA::Exception ex  )  [static]

Narrow to an UnknowUserException.

Reimplemented from CORBA::UserException.

Definition at line 58 of file Unknown_User_Exception.cpp.

00059 {
00060   return dynamic_cast<CORBA::UnknownUserException *> (ex);
00061 }

void CORBA::UnknownUserException::_raise ( void   )  const [virtual]

To throw an UnknownUserException of this type.

Implements CORBA::UserException.

Definition at line 70 of file Unknown_User_Exception.cpp.

00071 {
00072   throw *this;
00073 }

const char * CORBA::UnknownUserException::_rep_id ( void   )  const [virtual]

Return the repository ID of the Exception.

Reimplemented from CORBA::Exception.

Definition at line 100 of file Unknown_User_Exception.cpp.

References exception_.

00101 {
00102   return this->exception_->_tao_get_typecode ()->id ();
00103 }

void CORBA::UnknownUserException::_tao_decode ( TAO_InputCDR cdr  )  [virtual]

Implements CORBA::Exception.

Definition at line 94 of file Unknown_User_Exception.cpp.

00095 {
00096   throw ::CORBA::MARSHAL ();
00097 }

CORBA::Exception * CORBA::UnknownUserException::_tao_duplicate ( void   )  const [virtual]

Implements CORBA::Exception.

Definition at line 76 of file Unknown_User_Exception.cpp.

References ACE_NEW_RETURN.

00077 {
00078   CORBA::Exception *result;
00079   ACE_NEW_RETURN (
00080       result,
00081       CORBA::UnknownUserException (*this),
00082       0
00083     );
00084   return result;
00085 }

void CORBA::UnknownUserException::_tao_encode ( TAO_OutputCDR cdr  )  const [virtual]

Implements CORBA::Exception.

Definition at line 88 of file Unknown_User_Exception.cpp.

00089 {
00090   throw ::CORBA::MARSHAL ();
00091 }

CORBA::TypeCode_ptr CORBA::UnknownUserException::_tao_type ( void   )  const [virtual]

This class has a specific typecode.

Reimplemented from CORBA::UserException.

Definition at line 106 of file Unknown_User_Exception.cpp.

References exception_.

00107 {
00108   //return CORBA::_tc_UnknownUserException;
00109   return this->exception_->_tao_get_typecode ();
00110 }


Member Data Documentation

CORBA::Any* CORBA::UnknownUserException::exception_ [private]

Holder for the actual exception.

Definition at line 99 of file Unknown_User_Exception.h.

Referenced by _rep_id(), _tao_type(), UnknownUserException(), and ~UnknownUserException().

CORBA::Any& exception CORBA::UnknownUserException::void

Return the any containing the user exception.

Definition at line 76 of file Unknown_User_Exception.h.


The documentation for this class was generated from the following files:
Generated on Tue Feb 2 17:43:31 2010 for TAO_DynamicInterface by  doxygen 1.4.7