UserException.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00003 //=============================================================================
00004 /**
00005  *  @file    UserException.h
00006  *
00007  *  UserException.h,v 1.4 2006/04/19 08:59:15 jwillemsen Exp
00008  *
00009  *  CORBA::UserException class header.
00010  *
00011  *  @author DOC Group at Vanderbilt U, Wash U, and UCI
00012  *  @author Ossama Othman <ossama@dre.vanderbilt.edu>
00013  */
00014 //=============================================================================
00015 
00016 #ifndef TAO_USER_EXCEPTION_H
00017 #define TAO_USER_EXCEPTION_H
00018 
00019 #include /**/ "ace/pre.h"
00020 
00021 #include "tao/TAO_Export.h"
00022 
00023 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00024 # pragma once
00025 #endif /* ACE_LACKS_PRAGMA_ONCE */
00026 
00027 #include "tao/Exception.h"
00028 
00029 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00030 
00031 namespace CORBA
00032 {
00033   /**
00034    * @class UserException
00035    *
00036    * @brief Application- or OMG- defined CORBA exception sub-class.
00037    *
00038    * User exceptions can be defined in application OMG IDL or by the
00039    * OMG itself for IDL interfaces and services it defines.
00040    */
00041   class TAO_Export UserException : public Exception
00042   {
00043   public:
00044 
00045     /// Copy constructor.
00046     UserException (UserException const & rhs);
00047 
00048     /// Destructor.
00049     virtual ~UserException (void);
00050 
00051     /// Assignment operator.
00052     UserException & operator= (UserException const & rhs);
00053 
00054     /// The narrow operation.
00055     static UserException * _downcast (CORBA::Exception * exception);
00056 
00057         /// The const version of narrow operation
00058     static const UserException * _downcast (
00059       CORBA::Exception const * exception);
00060 
00061     virtual void _raise (void) const = 0;
00062 
00063     virtual CORBA::TypeCode_ptr _tao_type (void) const;
00064 
00065     // = TAO specific extension.
00066 
00067     /// Constructor from a repository id.
00068     UserException (char const * repository_id,
00069                    char const * local_name);
00070 
00071     /// Returns a string containing information about the exception. This
00072     /// function is not CORBA compliant.
00073     virtual ACE_CString _info (void) const;
00074 
00075   protected:
00076     /// Default constructor.
00077     UserException (void);
00078   };
00079 
00080 }
00081 
00082 TAO_END_VERSIONED_NAMESPACE_DECL
00083 
00084 #if defined (__ACE_INLINE__)
00085 # include "tao/UserException.inl"
00086 #endif /* __ACE_INLINE__ */
00087 
00088 #include /**/"ace/post.h"
00089 
00090 #endif /* TAO_USER_EXCEPTION_H */

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