#include <error.h>
Public Member Functions | |
Error (ErrorCode code=kUnknownError) | |
Error (ErrorCode code, const String &extra) | |
String | getDesc () const |
U32String | getTranslatedDesc () const |
ErrorCode | getCode () const |
Protected Attributes | |
ErrorCode | _code |
String | _desc |
An Error instance pairs an error code with string description providing more details about the error. For every error code, a default description is provided, but it is possible to optionally augment that description with extra information when creating a new Error instance.
Common::Error::Error | ( | ErrorCode | code = kUnknownError | ) |
Construct a new Error with the specified error code and the default error message.
Construct a new Error with the specified error code and an augmented error message. Specifically, the provided extra text is suitably appended to the default message.
String Common::Error::getDesc | ( | ) | const |
Get the untranslated description of this error.
U32String Common::Error::getTranslatedDesc | ( | ) | const |
Get the translated description of this error.
|
inline |
Get the error code of this error.