Structure to define the return characteristics of each function. More...
#include <status.hpp>
Public Types | |
enum | { OK = 0 , FILE_ERROR , INVALID_PARAMETER , INCOMPATIBLE_PARAMETER , CONFIGURATION_ERROR , REGISTER_IO_ERROR , NOT_IMPLEMENTED , MEMBER_ABSENT , RESOURCE_BUSY , EXECUTION_FAILED , REGISTER_NOT_ALIGNED } |
Public Member Functions | |
Status () noexcept | |
Construct a new Status object. More... | |
Status (const int code, const std::string &msg) noexcept | |
Construct a new Status object. More... | |
Status (const int code, const int retval, const std::string &msg) noexcept | |
Construct a new Status object. More... | |
Data Fields | |
int | code |
int | retval |
std::string | msg |
Structure to define the return characteristics of each function.
It includes a code and a description that works to track errors
anonymous enum |
Error codes
Enumerator | |
---|---|
FILE_ERROR | OK Status |
INVALID_PARAMETER | File error that can be read or write |
INCOMPATIBLE_PARAMETER | Invalid argument or parameter. i.e. nullptr Incompatible parameter that it is not supported by a function |
REGISTER_IO_ERROR | Configuration error |
NOT_IMPLEMENTED | Register MMIO error |
MEMBER_ABSENT | Not implemented error |
RESOURCE_BUSY | Missing member |
EXECUTION_FAILED | Busy |
REGISTER_NOT_ALIGNED | Cannot execute the IP |
|
inlinenoexcept |
|
inlinenoexcept |
Construct a new Status object.
It defines the constructor to define a custom code and description
code | code of the error |
msg | description |
|
inlinenoexcept |
Construct a new Status object.
It defines the constructor to define a custom code and description
code | code of the error |
retval | return value in case of integer |
msg | description |
std::string cynq::Status::msg |
Auxiliar data coming from user
int cynq::Status::retval |
Code of the error