Public Member Functions | Static Public Member Functions | Public Attributes

CORBA::PolicyError Class Reference

#include <PolicyC.h>

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

List of all members.

Public Member Functions

 PolicyError (void)
 PolicyError (const PolicyError &)
 ~PolicyError (void)
PolicyErroroperator= (const PolicyError &)
virtual CORBA::Exception_tao_duplicate (void) const
 Deep copy.
virtual void _raise (void) const
virtual void _tao_encode (TAO_OutputCDR &) const
virtual void _tao_decode (TAO_InputCDR &)
 PolicyError (::CORBA::PolicyErrorCode _tao_reason)
virtual CORBA::TypeCode_ptr _tao_type (void) const
 Will be overridden in the concrete derived classes.

Static Public Member Functions

static void _tao_any_destructor (void *)
 Used in the non-copying Any insertion operator.
static PolicyError_downcast (CORBA::Exception *)
 The narrow operation.
static const PolicyError_downcast (CORBA::Exception const *)
 The const version of narrow operation.
static CORBA::Exception_alloc (void)

Public Attributes

CORBA::PolicyErrorCode reason

Detailed Description

Definition at line 117 of file PolicyC.h.


Constructor & Destructor Documentation

CORBA::PolicyError::PolicyError ( void   ) 

Definition at line 97 of file PolicyC.cpp.

  : CORBA::UserException (
        "IDL:omg.org/CORBA/PolicyError:1.0",
        "PolicyError"
      )
{
}

CORBA::PolicyError::PolicyError ( const PolicyError  ) 
CORBA::PolicyError::~PolicyError ( void   ) 

Definition at line 105 of file PolicyC.cpp.

{
}

CORBA::PolicyError::PolicyError ( ::CORBA::PolicyErrorCode  _tao_reason  ) 

Member Function Documentation

CORBA::Exception * CORBA::PolicyError::_alloc ( void   )  [static]

Definition at line 145 of file PolicyC.cpp.

{
  CORBA::Exception *retval = 0;
  ACE_NEW_RETURN (retval, ::CORBA::PolicyError, 0);
  return retval;
}

CORBA::PolicyError * CORBA::PolicyError::_downcast ( CORBA::Exception exception  )  [static]

The narrow operation.

Reimplemented from CORBA::UserException.

Definition at line 134 of file PolicyC.cpp.

{
  return dynamic_cast<PolicyError *> (_tao_excp);
}

const CORBA::PolicyError * CORBA::PolicyError::_downcast ( CORBA::Exception const *  exception  )  [static]

The const version of narrow operation.

Reimplemented from CORBA::UserException.

Definition at line 140 of file PolicyC.cpp.

{
  return dynamic_cast<const PolicyError *> (_tao_excp);
}

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

Implements CORBA::UserException.

Definition at line 164 of file PolicyC.cpp.

{
  throw *this;
}

void CORBA::PolicyError::_tao_any_destructor ( void *  x  )  [static]

Used in the non-copying Any insertion operator.

Reimplemented from CORBA::Exception.

Definition at line 126 of file PolicyC.cpp.

{
  PolicyError *_tao_tmp_pointer =
    static_cast<PolicyError *> (_tao_void_pointer);
  delete _tao_tmp_pointer;
}

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

Implements CORBA::Exception.

Definition at line 182 of file PolicyC.cpp.

{
  if (cdr >> *this)
    {
      return;
    }

  throw ::CORBA::MARSHAL ();
}

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

Deep copy.

The following operation is used in the implementation of it performs a deep copy of the exception, normally it is implemented as:

 class SomeException : public // Derives from CORBA::Exception
 {
 public:
   virtual CORBA::Exception *_tao_duplicate (void) const
   {
     CORBA::Exception *result = 0;
     ACE_NEW_RETURN (
         result,
         SomeException (*this),
         0
       );
     return result;
   }
 };
 

Implements CORBA::Exception.

Definition at line 153 of file PolicyC.cpp.

{
  CORBA::Exception *result = 0;
  ACE_NEW_RETURN (
      result,
      ::CORBA::PolicyError (*this),
      0
    );
  return result;
}

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

Implements CORBA::Exception.

Definition at line 169 of file PolicyC.cpp.

{
  if (cdr << *this)
    {
      return;
    }

  throw ::CORBA::MARSHAL ();
}

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

Will be overridden in the concrete derived classes.

Reimplemented from CORBA::UserException.

Definition at line 212 of file PolicyC.cpp.

{
  TAO_AnyTypeCode_Adapter *adapter =
    ACE_Dynamic_Service<TAO_AnyTypeCode_Adapter>::instance (
        "AnyTypeCode_Adapter"
      );
  if (adapter != 0)
    return adapter->_tao_type_PolicyError ();
  else
    {
      ACE_ERROR ((LM_ERROR,
                  ACE_TEXT ("(%P|%t) %p\n"),
                  ACE_TEXT ("Unable to find the ")
                  ACE_TEXT ("AnyTypeCode Adapter instance")));
      return 0;
    }
}

PolicyError& CORBA::PolicyError::operator= ( const PolicyError  ) 

Member Data Documentation

Definition at line 121 of file PolicyC.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines