#include <irtkException.h>


Definition at line 22 of file irtkException.h.
Public Member Functions | |
| irtkException (const std::string &message, const std::string &fileName="", unsigned int line=0) | |
| Constructor takes message, file name and line number at which exception was thrown. | |
| const std::string & | GetMessage () const |
| Returns the message. | |
| const std::string & | GetFileName () const |
| Returns the name of the file in which the exception was thrown. | |
| unsigned int | GetLine () const |
| Returns the line number at which the exception was thrown. | |
Protected Attributes | |
| std::string | _Message |
| The message. | |
| std::string | _FileName |
| The file name. | |
| unsigned int | _Line |
| The line number at which the exception was thrown. | |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const irtkException &ex) |
| Outputs the exception to a stream. | |
| irtkException::irtkException | ( | const std::string & | message, | |
| const std::string & | fileName = "", |
|||
| unsigned int | line = 0 | |||
| ) | [inline] |
Constructor takes message, file name and line number at which exception was thrown.
| message | The message. | |
| file | The file name. You can use the __FILE__ macro to get the file name. | |
| line | The line number at which the exception was thrown. You can use the __LINE__ macro to get the line number. |
Definition at line 60 of file irtkException.h.
| const std::string & irtkException::GetMessage | ( | ) | const [inline] |
| const std::string & irtkException::GetFileName | ( | ) | const [inline] |
Returns the name of the file in which the exception was thrown.
Definition at line 73 of file irtkException.h.
References _FileName.
| unsigned int irtkException::GetLine | ( | ) | const [inline] |
Returns the line number at which the exception was thrown.
Definition at line 78 of file irtkException.h.
References _Line.
| std::ostream& operator<< | ( | std::ostream & | os, | |
| const irtkException & | ex | |||
| ) | [friend] |
Outputs the exception to a stream.
| os | The output stream. | |
| ex | The exception. |
std::string irtkException::_Message [protected] |
The message.
Definition at line 51 of file irtkException.h.
Referenced by GetMessage(), and irtkException().
std::string irtkException::_FileName [protected] |
The file name.
Definition at line 54 of file irtkException.h.
Referenced by GetFileName(), and irtkException().
unsigned int irtkException::_Line [protected] |
The line number at which the exception was thrown.
Definition at line 57 of file irtkException.h.
Referenced by GetLine(), and irtkException().