libcommonc++  0.7
Exception Class Reference

A general-purpose exception. More...

#include <Exception.h++>

Inheritance diagram for Exception:
Collaboration diagram for Exception:

Public Member Functions

 Exception (String message=String::empty)
 Construct a new Exception with an optional cause message. More...
 
virtual ~Exception () throw ()
 Destructor. More...
 
String getMessage () const
 Get the message associated with the exception. More...
 
virtual const char * what () const throw ()
 Get the message associated with the exception. More...
 
virtual void write (std::ostream &stream) const
 Write a textual representation of the exception to a stream. More...
 
String toString () const
 Get a textual representation of the exception as a String. More...
 

Protected Attributes

String _message
 The cause message. More...
 
CString _what
 

Detailed Description

A general-purpose exception.

Author
Mark Lindner

Constructor & Destructor Documentation

◆ Exception()

Exception ( String  message = String::empty)

Construct a new Exception with an optional cause message.

◆ ~Exception()

virtual ~Exception ( )
throw (
)
inlinevirtual

Destructor.

Member Function Documentation

◆ getMessage()

String getMessage ( ) const
inline

Get the message associated with the exception.

◆ toString()

String toString ( ) const
inline

Get a textual representation of the exception as a String.

◆ what()

const char * what ( ) const
throw (
)
virtual

Get the message associated with the exception.

◆ write()

Member Data Documentation

◆ _message

String _message
protected

The cause message.

◆ _what

CString _what
mutableprotected

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