dora_next_event

Function dora_next_event 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn dora_next_event( context: *mut c_void, ) -> *mut c_void
Expand description

Waits for the next incoming event for the node.

Returns a pointer to the event on success. This pointer must not be used directly. Instead, use the read_dora_event_* functions to read out the type and payload of the event. When the event is not needed anymore, use free_dora_event to free it again.

Returns a null pointer when all event streams were closed. This means that no more event will be available. Nodes typically react by stopping.

ยงSafety

The context argument must be a dora context created through init_dora_context_from_env. The context must be still valid, i.e., not freed yet.