3 #include "nta/Errors.h"
11 std::cout<<
"An error occured. Check Log.log for details"<<std::endl;
50 case MISSING_RESOURCE:
51 return "Missing Resource";
53 return "Invalid value";
59 return "DevIL Failure";
60 case IMPOSSIBLE_BEHAVIOR:
61 return "Impossible Behavior";
62 case UNWRAP_WRONG_RESULT_VARIANT:
63 return "Unwrapped wrong result variant";
static void set_push_callback(const ErrorCallback &callback)
Sets the push callback function.
static ErrorCallback m_periodic_callback
The function used to handle errors at the end of each frame.
static const Error * m_errors
A linked list of unhandled errors.
static void push_error(const Error &err)
Adds and error to the front of the list.
const Error * prev
The most recent unhandled error before this one.
std::string get_errortype_string(ErrorType t)
converts ErrorType enum to string
static const Error * peek_error()
Returns the error at the front of the list.
static const Error * pop_error()
Removes (and returns) the error from the front of the list.
static void clear_errors()
Deletes all errors (without handling any of them)
static void set_periodic_callback(const ErrorCallback &callback)
Sets the periodic callback function.
static ErrorCallback m_push_callback
The function used to handle errors as they occur.
static void handle_errors()
Handles all outstanding errors.
void cleanup()
deinitializes some stuff and destroys all managers