#include <it_bus/exception.h>
Inheritance diagram for IT_Bus::Exception:
All User or System exceptions derive from this base class
Definition at line 22 of file exception.h.
Public Member Functions | |
Exception (const String &message) | |
Constructor. | |
Exception (const char *desc1=0, const char *desc2=0, const char *desc3=0, const char *desc4=0, const char *desc5=0, const char *desc6=0) | |
Constructor. | |
Exception (IT_ULong error_code, const char *desc1=0, const char *desc2=0, const char *desc3=0, const char *desc4=0, const char *desc5=0, const char *desc6=0) | |
Constructor. | |
Exception (const Exception &rhs) | |
Copy constructor. | |
virtual | ~Exception () |
Destructor. | |
Exception & | operator= (const Exception &rhs) |
Assigment operator. | |
void | create_message (const char *desc1=0, const char *desc2=0, const char *desc3=0, const char *desc4=0, const char *desc5=0, const char *desc6=0) |
This will change the message for the Exception by overwriting the message used to create the Exception originally. | |
const char * | message () const |
Return the exception message. | |
IT_ULong | error () const |
Return the exception error code. | |
virtual Exception * | clone () const |
Clone the exception onto the heap. | |
virtual void | rethrow () const |
Rethrow the exception. | |
Private Attributes | |
CCountedString | m_msg |
IT_ULong | m_error |
IT_Bus::Exception::Exception | ( | const String & | message | ) |
Constructor.
The single argument becomes the message encapsulated within the exception.
IT_Bus::Exception::Exception | ( | const char * | desc1 = 0 , |
|
const char * | desc2 = 0 , |
|||
const char * | desc3 = 0 , |
|||
const char * | desc4 = 0 , |
|||
const char * | desc5 = 0 , |
|||
const char * | desc6 = 0 | |||
) |
Constructor.
One to six arguments may be provided. The message encapsulated within the exception is constructed from the arguments.
IT_Bus::Exception::Exception | ( | IT_ULong | error_code, | |
const char * | desc1 = 0 , |
|||
const char * | desc2 = 0 , |
|||
const char * | desc3 = 0 , |
|||
const char * | desc4 = 0 , |
|||
const char * | desc5 = 0 , |
|||
const char * | desc6 = 0 | |||
) |
Constructor.
The first argument becomes the error code encapsulated within the exception. The other arguments become the exception message.
void IT_Bus::Exception::create_message | ( | const char * | desc1 = 0 , |
|
const char * | desc2 = 0 , |
|||
const char * | desc3 = 0 , |
|||
const char * | desc4 = 0 , |
|||
const char * | desc5 = 0 , |
|||
const char * | desc6 = 0 | |||
) |
This will change the message for the Exception by overwriting the message used to create the Exception originally.
The parameters are defaulted so you can pass between 0 and 6 different const char* messages to this.
const | char* desc1 contains a message | |
const | char* desc2 contains a message | |
const | char* desc3 contains a message | |
const | char* desc4 contains a message | |
const | char* desc5 contains a message | |
const | char* desc6 contains a message |
IT_ULong IT_Bus::Exception::error | ( | ) | const |
const char* IT_Bus::Exception::message | ( | ) | const |