Error description (API) More...
Public Member Functions | |
Error (const string &reason) | |
Error (const char *format,...) | |
Error (int code, const string &reason) | |
Error (int code, const char *format,...) | |
Error (const Error &error) | |
string | getReason () const |
int | getCode () const |
string | textWhere () const |
string | htmlWhere () const |
Public Member Functions inherited from Hurricane::Exception | |
string | what () const |
string | textWhat () const |
string | htmlWhat () const |
Additional Inherited Members | |
Static Public Member Functions inherited from Hurricane::Exception | |
static void | setTextTranslator (const TextTranslator &translator) |
static void | setHtmlTranslator (const TextTranslator &translator) |
Error description (API)
Errors are printed with different formats wether the error code is null or not : text: So the following code :
Will produce the message :
while the following code :
Will produce the message :
You can always print something different as shown in the following code :
Which will produce the message :
Hurricane::Error::Error | ( | const string & | reason | ) |
Builds a error characterized by a reason (code defaults to zero).
Hurricane::Error::Error | ( | const char * | format, |
... | |||
) |
Builds a error characterized by a reason, using the vararg
protocol and printf
format (code defaults to zero).
Hurricane::Error::Error | ( | int | code, |
const string & | reason | ||
) |
Builds a error characterized by a reason and a code useful within a switch.
Hurricane::Error::Error | ( | int | code, |
const char * | format, | ||
... | |||
) |
Builds a error characterized by a reason and a code useful within a switch. The reason is supplied in a printf
like fashion.
Hurricane::Error::Error | ( | const Error & | error | ) |
Copy constructor.
|
inline |
Returns: the reason for which the error was thrown.
|
inline |
Returns: the error code number.
|
inline |
Returns: A stack trace, suitable for tty.
|
inline |
Returns: A stack trace, suitable for HTML.
Generated by doxygen 1.9.1 on Thu Aug 11 2022 | Return to top of page |
Hurricane VLSI Database | Copyright © 2000-2020 Bull S.A. All rights reserved |