A short fixed list of callbacks, run in the order they were added. More...
#include <stdbool.h>Go to the source code of this file.
Data Structures | |
| struct | CallbackList |
| A list over storage its owner provides. Start it as {entries, max, 0}. More... | |
Typedefs | |
| typedef void(*) | CallbackListFn(void) |
| One callback in a list. | |
Functions | |
| bool | callback_list_add (CallbackList *list, CallbackListFn cb) |
| Adds a callback to the end of the list. Adding one that is already there does nothing. | |
| void | callback_list_fire (const CallbackList *list) |
| Runs every callback in the order it was added. | |
A short fixed list of callbacks, run in the order they were added.
The stores hang their periodic work on one of these, and the transport keeps another for the work that waits until a whole inbound message is handled. Each list lives in the file that owns it, with room set by how many callers there can be, so nothing here allocates.