|
OSAPI
0.29
Open System API
|
File providing public definitions for the status module. More...
#include <stdbool.h>#include "error/error_types.h"

Go to the source code of this file.
Macros | |
| #define | status_reset(x) ( (x)->code = 0 ) |
| Resets the status structure (to success) | |
| #define | status_set(m, t, f, e, r) status_instance_set( m, t, f, e, r ) |
| See status_instance_set function. | |
| #define | status_setString(m, t, f, s, r) status_instance_setString( m, t, f, s, r ) |
| See status_instance_setString function. | |
| #define | status_success(x) ( x.code == 0 ) |
| Returns true if the operation that returned x was successful. More... | |
| #define | status_failure(x) ( x.code != 0 ) |
| Returns true if the operation that returned x failed. More... | |
| #define | status_error(s, e) ( s.code == e ) |
| Match a given error. More... | |
| #define | status_true( x) ( status_failure( x ) ? 0 : 1 ) |
| Check if the status result of the operation is true. More... | |
| #define | status_false(x) ( status_success( x ) ? 1 : 0 ) |
| Check if the status result of the operation is true. More... | |
| #define | status_result(x) ( x.code == 0 ? true : false ) |
| Get the operation status result: success==true/failure==false. | |
| #define | status_unsupported(s) ( s.code == OSAPI_ERROR_SUPPORT ) |
| Find if a module or facility is supported. More... | |
File providing public definitions for the status module.
| #define status_error | ( | s, | |
| e | |||
| ) | ( s.code == e ) |
Match a given error.
| #define status_failure | ( | x | ) | ( x.code != 0 ) |
Returns true if the operation that returned x failed.
| #define status_false | ( | x | ) | ( status_success( x ) ? 1 : 0 ) |
Check if the status result of the operation is true.
| #define status_success | ( | x | ) | ( x.code == 0 ) |
Returns true if the operation that returned x was successful.
| #define status_true | ( | x | ) | ( status_failure( x ) ? 0 : 1 ) |
Check if the status result of the operation is true.
| #define status_unsupported | ( | s | ) | ( s.code == OSAPI_ERROR_SUPPORT ) |
Find if a module or facility is supported.