Hyperon C
Loading...
Searching...
No Matches
space_observer_api_t Struct Reference

A table of callback functions to define the behavior of a SpaceObserver implemented in C. More...

#include <hyperon.h>

Public Attributes

void(* notify )(void *payload, const struct space_event_t *event)
 Called to pass an event to the observer.
void(* free_payload )(void *payload)
 Responsible for freeing the payload passed to space_register_observer

Detailed Description

A table of callback functions to define the behavior of a SpaceObserver implemented in C.

See also
space_register_observer

Member Data Documentation

◆ free_payload

void(* space_observer_api_t::free_payload) (void *payload)

Responsible for freeing the payload passed to space_register_observer

Parameters
[in]payloadThe pointer to the observer's payload to free
Note
This function is responsible for freeing the payload buffer, as well as any other objects and resources owned by the observer.

◆ notify

void(* space_observer_api_t::notify) (void *payload, const struct space_event_t *event)

Called to pass an event to the observer.

Parameters
[in]payloadThe pointer to the observer's payload
[in]eventThe event the observer is notified about

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