|
Safe API Framework
Layered API framework for safety-related applications (ERTMS RBC reference targeting CENELEC EN 50128 SIL 4)
|
Fixed-capacity {callback, context} list shape (ADR-030). More...
Macros | |
| #define | SAFEAPI_DECLARE_CALLBACK_LIST(list_type, callback_fn_type, max_subscribers) |
| Declares a fixed-capacity list of {callback, context} slots for one concretely-typed callback function pointer - see this file's own header for the full usage pattern (init/register/ dispatch are hand-written against the declared type, not generated by this macro). | |
Fixed-capacity {callback, context} list shape (ADR-030).
| #define SAFEAPI_DECLARE_CALLBACK_LIST | ( | list_type, | |
| callback_fn_type, | |||
| max_subscribers ) |
Declares a fixed-capacity list of {callback, context} slots for one concretely-typed callback function pointer - see this file's own header for the full usage pattern (init/register/ dispatch are hand-written against the declared type, not generated by this macro).
| list_type | Name of the generated list type. |
| callback_fn_type | An already-declared function pointer typedef (e.g. typedef bool (*my_fn)(void *, ...)). |
| max_subscribers | Fixed slot count (compile-time constant). |
Usage: SAFEAPI_DECLARE_CALLBACK_LIST(my_validator_list_t, my_validator_fn, 2U);
Definition at line 136 of file sapi_notify.h.