Callbacks to contact the Janus core. More...
#include <plugin.h>
Data Fields | |
int(*const | push_event )(janus_plugin_session *handle, janus_plugin *plugin, const char *transaction, json_t *message, json_t *jsep) |
Callback to push events/messages to a peer. | |
void(*const | relay_rtp )(janus_plugin_session *handle, janus_plugin_rtp *packet) |
Callback to relay RTP packets to a peer. | |
void(*const | relay_rtcp )(janus_plugin_session *handle, janus_plugin_rtcp *packet) |
Callback to relay RTCP messages to a peer. | |
void(*const | relay_data )(janus_plugin_session *handle, janus_plugin_data *packet) |
Callback to relay SCTP/DataChannel messages to a peer. | |
void(*const | send_pli )(janus_plugin_session *handle) |
Helper to ask for a keyframe via a RTCP PLI. | |
void(*const | send_remb )(janus_plugin_session *handle, guint32 bitrate) |
Helper to ask for a keyframe via a RTCP PLI. | |
void(*const | close_pc )(janus_plugin_session *handle) |
Callback to ask the core to close a WebRTC PeerConnection. | |
void(*const | end_session )(janus_plugin_session *handle) |
Callback to ask the core to get rid of a plugin/gateway session. | |
gboolean(*const | events_is_enabled )(void) |
Callback to check whether the event handlers mechanism is enabled. | |
void(*const | notify_event )(janus_plugin *plugin, janus_plugin_session *handle, json_t *event) |
Callback to notify an event to the registered and subscribed event handlers. | |
gboolean(*const | auth_is_signed )(void) |
Method to check whether the core is using signed tokens. | |
gboolean(*const | auth_is_signature_valid )(janus_plugin *plugin, const char *token) |
Method to check whether a signed token is valid. | |
gboolean(*const | auth_signature_contains )(janus_plugin *plugin, const char *token, const char *descriptor) |
Method to verify a signed token grants access to a descriptor. | |
Callbacks to contact the Janus core.
gboolean(*const janus_callbacks::auth_is_signature_valid) (janus_plugin *plugin, const char *token) |
Method to check whether a signed token is valid.
[in] | token | The token to validate |
gboolean(*const janus_callbacks::auth_is_signed) (void) |
Method to check whether the core is using signed tokens.
gboolean(*const janus_callbacks::auth_signature_contains) (janus_plugin *plugin, const char *token, const char *descriptor) |
Method to verify a signed token grants access to a descriptor.
[in] | token | The token to validate |
[in] | desc | The descriptor to search for |
void(*const janus_callbacks::close_pc) (janus_plugin_session *handle) |
Callback to ask the core to close a WebRTC PeerConnection.
[in] | handle | The plugin/gateway session that the PeerConnection is related to |
void(*const janus_callbacks::end_session) (janus_plugin_session *handle) |
Callback to ask the core to get rid of a plugin/gateway session.
[in] | handle | The plugin/gateway session to get rid of |
gboolean(*const janus_callbacks::events_is_enabled) (void) |
Callback to check whether the event handlers mechanism is enabled.
void(*const janus_callbacks::notify_event) (janus_plugin *plugin, janus_plugin_session *handle, json_t *event) |
Callback to notify an event to the registered and subscribed event handlers.
[in] | plugin | The plugin originating the event |
[in] | handle | The plugin/gateway session originating the event, if any |
[in] | event | The event to notify as a Jansson json_t object |
int(*const janus_callbacks::push_event) (janus_plugin_session *handle, janus_plugin *plugin, const char *transaction, json_t *message, json_t *jsep) |
Callback to push events/messages to a peer.
message
and jsep
json_t objects. This means that you'll have to decrease your own reference yourself with a json_decref
after calling push_event
[in] | handle | The plugin/gateway session used for this peer |
[in] | plugin | The plugin instance that is sending the message/event |
[in] | transaction | The transaction identifier this message refers to |
[in] | message | The json_t object containing the JSON message |
[in] | jsep | The json_t object containing the JSEP type, the SDP attached to the message/event, if any (offer/answer), and whether this is an update |
void(*const janus_callbacks::relay_data) (janus_plugin_session *handle, janus_plugin_data *packet) |
Callback to relay SCTP/DataChannel messages to a peer.
[in] | handle | The plugin/gateway session that will be used for this peer |
[in] | packet | The message data and related info |
void(*const janus_callbacks::relay_rtcp) (janus_plugin_session *handle, janus_plugin_rtcp *packet) |
Callback to relay RTCP messages to a peer.
[in] | handle | The plugin/gateway session that will be used for this peer |
[in] | packet | The RTCP packet and related data |
void(*const janus_callbacks::relay_rtp) (janus_plugin_session *handle, janus_plugin_rtp *packet) |
Callback to relay RTP packets to a peer.
[in] | handle | The plugin/gateway session used for this peer |
[in] | packet | The RTP packet and related data |
void(*const janus_callbacks::send_pli) (janus_plugin_session *handle) |
Helper to ask for a keyframe via a RTCP PLI.
[in] | handle | The plugin/gateway session that will be used for this peer |
void(*const janus_callbacks::send_remb) (janus_plugin_session *handle, guint32 bitrate) |
Helper to ask for a keyframe via a RTCP PLI.
[in] | handle | The plugin/gateway session that will be used for this peer |
[in] | bitrate | The bitrate value to send in the REMB message |