A "timeout" instance used by an async_context. More...
#include <async_context.h>
Data Fields | |
struct async_work_on_timeout * | next |
void(* | do_work )(async_context_t *context, struct async_work_on_timeout *timeout) |
absolute_time_t | next_time |
void * | user_data |
A "timeout" instance used by an async_context.
A "timeout" represents some future action that must be taken at a specific time. It's methods are called from the async_context under lock at the given time
void(* async_work_on_timeout::do_work) (async_context_t *context, struct async_work_on_timeout *timeout) |
Method called when the timeout is reached; may not be NULL
Note, that when this method is called, the timeout has been removed from the async_context, so if you want the timeout to repeat, you should re-add it during this callback
context | |
timeout |
struct async_work_on_timeout* async_work_on_timeout::next |
private link list pointer
absolute_time_t async_work_on_timeout::next_time |
The next timeout time; this should only be modified during the above methods or via async_context methods
void* async_work_on_timeout::user_data |
User data associated with the timeout instance