86 #ifndef _JANUS_EVENTHANDLER_H 87 #define _JANUS_EVENTHANDLER_H 100 #include "../utils.h" 104 #define JANUS_EVENTHANDLER_API_VERSION 1 129 #define JANUS_EVENT_TYPE_NONE (0) 131 #define JANUS_EVENT_TYPE_SESSION (1 << 0) 133 #define JANUS_EVENT_TYPE_HANDLE (1 << 1) 135 #define JANUS_EVENT_TYPE_JSEP (1 << 3) 137 #define JANUS_EVENT_TYPE_WEBRTC (1 << 4) 139 #define JANUS_EVENT_TYPE_MEDIA (1 << 5) 141 #define JANUS_EVENT_TYPE_PLUGIN (1 << 6) 143 #define JANUS_EVENT_TYPE_TRANSPORT (1 << 7) 145 #define JANUS_EVENT_TYPE_CORE (1 << 8) 148 #define JANUS_EVENT_TYPE_ALL (0xffffffff) 151 #define JANUS_EVENTHANDLER_INIT(...) { \ 154 .get_api_compatibility = NULL, \ 155 .get_version = NULL, \ 156 .get_version_string = NULL, \ 157 .get_description = NULL, \ 159 .get_author = NULL, \ 160 .get_package = NULL, \ 161 .incoming_event = NULL, \ 162 .events_mask = JANUS_EVENT_TYPE_NONE, \ 177 int (*
const init)(
const char *config_path);
void(*const destroy)(void)
Event handler plugin deinitialization/destructor.
Definition: eventhandler.h:179
struct json_t json_t
Definition: plugin.h:219
janus_flags events_mask
Mask of events this handler is interested in, as a janus_flags object.
Definition: eventhandler.h:220
int(*const get_version)(void)
Informative method to request the numeric version of the event handler plugin.
Definition: eventhandler.h:186
const char *(*const get_version_string)(void)
Informative method to request the string version of the event handler plugin.
Definition: eventhandler.h:188
struct janus_eventhandler_callbacks janus_eventhandler_callbacks
Callbacks to contact the gateway.
Definition: eventhandler.h:167
void(*const incoming_event)(json_t *event)
Method to notify the event handler plugin that a new event is available.
Definition: eventhandler.h:217
The event handler plugin session and callbacks interface.
Definition: eventhandler.h:173
const char *(*const get_name)(void)
Informative method to request the name of the event handler plugin.
Definition: eventhandler.h:192
int(*const init)(const char *config_path)
Event handler plugin initialization/constructor.
Definition: eventhandler.h:177
uint32_t janus_flags
Janus flags container.
Definition: utils.h:85
const char *(*const get_description)(void)
Informative method to request a description of the event handler plugin.
Definition: eventhandler.h:190
int(*const get_api_compatibility)(void)
Informative method to request the API version this event handler plugin was compiled against...
Definition: eventhandler.h:184
const char *(*const get_author)(void)
Informative method to request the author of the event handler plugin.
Definition: eventhandler.h:194
const char *(*const get_package)(void)
Informative method to request the package name of the event handler plugin (what will be used in web ...
Definition: eventhandler.h:196
janus_eventhandler * create_e(void)
The hook that event handler plugins need to implement to be created from the gateway.
Definition: eventhandler.h:224