UnitySignaling¶
-
class
services.signaling.
UnitySignaling
(_websocket, _service)¶ Bases:
services.signaling.Signaling
WebRTCHandler base class
Parameters: {Tornado WebSocket} -- tornado base (tornado) – Methods Summary
get_next_id
()get next ID for webRtc user It should also set the self.id :returns: Int – next con_id new_connect
()new connection of a web_rtc user on_connect
()On connect is handled for newly opened websockets process_message
(message)Basic processing message translate_broadcast
(message, rtc_type)Translates a broadcast to other WebRTC clients This is a bit tricky as there is no standard for handling WebRTC in header-messages translate_init
(message, rtc_type[, _ws])Translates a init message to other WebRTC clients This is a bit tricky as there is no standard for handling WebRTC in header-messages translate_post_messages
(_response)Handler for special apprtc post messages Methods Documentation
-
get_next_id
()¶ get next ID for webRtc user It should also set the self.id :returns: Int – next con_id
-
new_connect
()¶ new connection of a web_rtc user
-
on_connect
()¶ On connect is handled for newly opened websockets
-
process_message
(message)¶ Basic processing message
Parameters: {bytes[]} -- signaling message (message) – Returns: response {bytes[]} – signaling response
-
translate_broadcast
(message, rtc_type)¶ Translates a broadcast to other WebRTC clients This is a bit tricky as there is no standard for handling WebRTC in header-messages
Parameters: - {bytes[]} -- current message (message) –
- {String} -- current rtc type (rtc_type) –
Raises: NotImplementedError
– If Signaling has no func included
-
translate_init
(message, rtc_type, _ws=None)¶ Translates a init message to other WebRTC clients This is a bit tricky as there is no standard for handling WebRTC in header-messages
Parameters: - {bytes[]} -- current message (message) –
- {String} -- current rtc type (rtc_type) –
Raises: NotImplementedError
– If Signaling has no func included
-
translate_post_messages
(_response)¶ Handler for special apprtc post messages
Parameters: {Dict<String, Obj>} -- responses dict (_response) –
-