void evs_query_init()
Intializes the ptrie for usage.
Events are stored in a prefix tree for fast, nice lookups.
Definition: evs.h:184
evs_on_fn on_fn
Called when client attempts to subscribe to event.
Definition: evs.h:198
gchar * ev_path
The event path for this node.
Definition: evs.h:188
enum evs_status(* evs_on_fn)(const struct evs_on_info *info)
The handler for when a client subscribes.
Definition: evs.h:179
struct event * evs_query_insert(const gchar *ev_path, const evs_handler_fn handler_fn, const evs_on_fn on_fn, const evs_off_fn off_fn, const gboolean handle_children)
Create a new event.
Every header, definition, and whatnot QuickIO needs to run.
evs_handler_fn handler_fn
Function called when client sends event to the server.
Definition: evs.h:193
evs_off_fn off_fn
Called when client unsubscribes from event.
Definition: evs.h:203
struct event * evs_query(const gchar *ev_path, gchar **ev_extra)
Finds an event by its path.
void(* evs_off_fn)(struct client *client, const gchar *ev_extra)
The handler for when a client unsubscribes.
Definition: evs.h:43
enum evs_status(* evs_handler_fn)(struct client *client, const gchar *ev_extra, const evs_cb_t client_cb, gchar *json)
The handler function type.
Definition: evs.h:31
gboolean handle_children
If this event wants to handle all children paths.
Definition: evs.h:208