Main   Namespaces   Classes   Hierarchy   Annotated   Files   Compound   Global   Pages  

BenzeneException Class Reference

Base class for exceptions. More...

#include <BenzeneException.hpp>

Inherits std::exception.

List of all members.

Public Member Functions

 BenzeneException ()
 Constructs an exception with no message.
 BenzeneException (const std::string &message)
 Construct an exception with the given message.
 BenzeneException (const BenzeneException &other)
 Needed for operator<<.
virtual ~BenzeneException () throw ()
 Destructor.
const char * what () const throw ()
 Returns the error message.
std::string Response () const
std::ostream & Stream ()

Private Attributes

std::ostringstream m_stream
std::string m_what

Related Functions

(Note that these are not member functions.)



template<typename TYPE >
BenzeneException operator<< (const BenzeneException &except, const TYPE &type)
template<typename TYPE >
BenzeneException operator<< (const BenzeneException &except, TYPE &type)

Detailed Description

Base class for exceptions.

Usage examples:

      BenzeneException("Message");
      BenzeneException() << "Message" << data << "more message.";
    

Definition at line 25 of file BenzeneException.hpp.


Constructor & Destructor Documentation

BenzeneException::BenzeneException (  ) 

Constructs an exception with no message.

Definition at line 13 of file BenzeneException.cpp.

BenzeneException::BenzeneException ( const std::string &  message  ) 

Construct an exception with the given message.

Definition at line 19 of file BenzeneException.cpp.

BenzeneException::BenzeneException ( const BenzeneException other  ) 

Needed for operator<<.

Definition at line 25 of file BenzeneException.cpp.

References m_stream, and Response().

BenzeneException::~BenzeneException (  )  throw () [virtual]

Destructor.

Definition at line 32 of file BenzeneException.cpp.


Member Function Documentation

std::string BenzeneException::Response (  )  const [inline]

Definition at line 59 of file BenzeneException.hpp.

References m_stream.

Referenced by BenzeneException(), and what().

std::ostream & BenzeneException::Stream (  )  [inline]

Definition at line 54 of file BenzeneException.hpp.

References m_stream.

Referenced by operator<<().

const char * BenzeneException::what (  )  const throw ()

Returns the error message.

Definition at line 36 of file BenzeneException.cpp.

References m_what, and Response().

Referenced by BookCommands::CmdBookOpen(), DfsCommands::CmdDBOpen(), and DfpnCommands::CmdOpenDB().


Friends And Related Function Documentation

template<typename TYPE >
BenzeneException operator<< ( const BenzeneException except,
TYPE &  type 
) [related]
Note:
Returns a new object, see BenzeneException

Definition at line 81 of file BenzeneException.hpp.

References Stream().

template<typename TYPE >
BenzeneException operator<< ( const BenzeneException except,
const TYPE &  type 
) [related]
Note:
Returns a new object, see BenzeneException

Definition at line 70 of file BenzeneException.hpp.

References Stream().


Member Data Documentation

std::ostringstream BenzeneException::m_stream [private]

Definition at line 49 of file BenzeneException.hpp.

Referenced by BenzeneException(), Response(), and Stream().

std::string BenzeneException::m_what [mutable, private]

Definition at line 51 of file BenzeneException.hpp.

Referenced by what().


The documentation for this class was generated from the following files:


6 Jan 2011 Doxygen 1.6.3