Loading...
Searching...
No Matches
async_context_type Struct Reference

Implementation of an async_context type, providing methods common to that type. More...

#include <async_context.h>

Data Fields

uint16_t type
 Numeric type identifier for this async_context implementation.
void(*) acquire_lock_blocking (async_context_t *self)
 Acquire the context lock, blocking until available.
void(*) release_lock (async_context_t *self)
 Release the context lock.
void(*) lock_check (async_context_t *self)
 Assert that the caller holds the context lock.
uint32_t(*) execute_sync (async_context_t *context, uint32_t(*func)(void *param), void *param)
 Execute a function synchronously on the context's core.
bool(*) add_at_time_worker (async_context_t *self, async_at_time_worker_t *worker)
 Add an at-time worker to the context.
bool(*) remove_at_time_worker (async_context_t *self, async_at_time_worker_t *worker)
 Remove an at-time worker from the context.
bool(*) add_when_pending_worker (async_context_t *self, async_when_pending_worker_t *worker)
 Add a when-pending worker to the context.
bool(*) remove_when_pending_worker (async_context_t *self, async_when_pending_worker_t *worker)
 Remove a when-pending worker from the context.
void(*) set_work_pending (async_context_t *self, async_when_pending_worker_t *worker)
 Mark a when-pending worker as having work to do.
void(*) poll (async_context_t *self)
 Poll for work; may be NULL for non-polled contexts.
void(*) wait_until (async_context_t *self, absolute_time_t until)
 Sleep until the specified time in a callback-safe manner.
void(*) wait_for_work_until (async_context_t *self, absolute_time_t until)
 Block until work is pending or the specified time is reached.
void(*) deinit (async_context_t *self)
 Deinitialise and free resources associated with the context.

Detailed Description

Implementation of an async_context type, providing methods common to that type.


The documentation for this struct was generated from the following file: