CuteHMI - CuteHMI (CuteHMI.2)
|
In-place error. More...
#include <cutehmi/InplaceError.hpp>
Public Member Functions | |
InplaceError (const QString &message="Error.", const char *file=nullptr, int line=0, const char *function=nullptr, int code=Error::FAIL) | |
Constructor. More... | |
QString | str () const |
Get error string. More... | |
Public Member Functions inherited from cutehmi::Error | |
Error () | |
Default constructor. More... | |
Error (int code) | |
Conversion constructor. More... | |
bool | operator== (const Error &other) const |
bool | operator!= (const Error &other) const |
operator bool () const | |
Conversion to bool . More... | |
int | code () const |
Get error code. More... | |
QString | str () const |
Get error string. More... | |
Public Attributes | |
QString | message |
const char * | file |
int | line |
const char * | function |
Additional Inherited Members | |
Public Types inherited from cutehmi::Error | |
enum | : int { UNINITIALIZED = -2 , FAIL = -1 , OK = 0 , SUBCLASS_BEGIN = 1 } |
Protected Member Functions inherited from cutehmi::Error | |
void | setCode (int code) |
In-place error.
This class can be more conveniently used with CUTEHMI_ERROR macro.
cutehmi::InplaceError::InplaceError | ( | const QString & | message = "Error." , |
const char * | file = nullptr , |
||
int | line = 0 , |
||
const char * | function = nullptr , |
||
int | code = Error::FAIL |
||
) |
Constructor.
message | error message. |
file | file name, where error occurred. |
line | line at which error occurred. |
function | function inside which error occurred. |
code | error code. |
QString cutehmi::InplaceError::str | ( | ) | const |
Get error string.
const char* cutehmi::InplaceError::file |
const char* cutehmi::InplaceError::function |
int cutehmi::InplaceError::line |
QString cutehmi::InplaceError::message |