![]() |
XII Release 0.1.0
|
Default enum for returning failure or success, instead of using a bool. More...
#include <Types.h>
Public Member Functions | |
xiiResult (xiiResultEnum res) | |
void | operator= (xiiResultEnum rhs) |
bool | operator== (xiiResultEnum cmp) const |
XII_ALWAYS_INLINE bool | Succeeded () const |
XII_ALWAYS_INLINE bool | Failed () const |
XII_ALWAYS_INLINE void | IgnoreResult () |
Used to silence compiler warnings, when success or failure doesn't matter. | |
void | AssertSuccess (const char *szMsg=nullptr, const char *szDetails=nullptr) const |
Asserts that the function succeeded. In case of failure, the program will terminate. | |
Default enum for returning failure or success, instead of using a bool.
void xiiResult::AssertSuccess | ( | const char * | szMsg = nullptr, |
const char * | szDetails = nullptr ) const |
Asserts that the function succeeded. In case of failure, the program will terminate.
If msg is given, this will be the assert message. If details is provided, msg should contain a formatting element ({}), e.g. "Error: {}".