schedule_event_and_dispatch
Name
schedule_event_and_dispatch — Schedule an event from any thread, and optionally dispatch the callback
Synopsis
#include "sp_async.h"
| void **schedule_event_and_dispatch** (
| e, | |
| | dispatch_mask)
; | |
Description
Schedule an event from any thread, and optionally dispatch the callback. When called from the scheduler thread, scheduling and dispatch can happen immediately.
When called from outside the scheduler thread, this adds the event scheduling and dispatch work to a queue in the scheduler. The scheduler will schedule and dispatch the event as soon as possible.
- e
-
The event.
- dispatch_mask
-
The event mask to pass to the event's callback. If non-zero, the callback is also dispatched. Otherwise, the event is just scheduled.
This function returns void.
It is legal to call this function in any thread.