Methods
CodecChoice | (u: Codec_ID) | → | nothing | |
Error | (u: Error_Code, s: Message) | → | nothing | |
NativeCandidatesPrepared | () | → | nothing | |
NewActiveCandidatePair | (s: Native_Candidate_ID, s: Remote_Candidate_ID) | → | nothing | |
NewActiveTransportPair | (s: Native_Candidate_ID, (usuussduss): Native_Transport, s: Remote_Candidate_ID, (usuussduss): Remote_Transport) | → | nothing | |
NewNativeCandidate | (s: Candidate_ID, a(usuussduss): Transports) | → | nothing | |
Ready | (a(usuuua{ss}): Codecs) | → | nothing | |
SetLocalCodecs | (a(usuuua{ss}): Codecs) | → | nothing | |
StreamState | (u: State) | → | nothing | |
SupportedCodecs | (a(usuuua{ss}): Codecs) | → | nothing | |
CodecsUpdated | (a(usuuua{ss}): Codecs) | → | nothing | |
HoldState | (b: Held) | → | nothing | |
UnholdFailure | () | → | nothing | |
SupportedFeedbackMessages | (a{u(ua(sss))}: Messages) | → | nothing | |
SupportedHeaderExtensions | (a(uuss): Header_Extensions) | → | nothing |
Signals
AddRemoteCandidate | (s: Candidate_ID, a(usuussduss): Transports) | |
Close | () | |
RemoveRemoteCandidate | (s: Candidate_ID) | (deprecated) |
SetActiveCandidatePair | (s: Native_Candidate_ID, s: Remote_Candidate_ID) | |
SetRemoteCandidateList | (a(sa(usuussduss)): Remote_Candidates) | |
SetRemoteCodecs | (a(usuuua{ss}): Codecs) | |
SetStreamPlaying | (b: Playing) | |
SetStreamSending | (b: Sending) | |
StartTelephonyEvent | (y: Event) | |
StartNamedTelephonyEvent | (y: Event, u: Codec_ID) | |
StartSoundTelephonyEvent | (y: Event) | |
StopTelephonyEvent | () | |
SetStreamHeld | (b: Held) | |
SetRemoteFeedbackMessages | (a{u(ua(sss))}: Messages) | |
SetRemoteHeaderExtensions | (a(uuss): Header_Extensions) |
Properties
STUNServers | a(sq) ( Socket_Address_IP_List) | Read only | ||
CreatedLocally | b | Read only | ||
NATTraversal | s | Read only | ||
RelayInfo | aa{sv} ( String_Variant_Map_List) | Read only |
Types
Media_Stream_Error | Enum | u | |
Media_Stream_Base_Proto | Enum | u | |
Media_Stream_Transport_Type | Enum | u | |
RTCP_Feedback_Message_Map | Mapping | a{u(ua(sss))} | |
Media_Stream_Handler_Candidate | Struct | (sa(usuussduss)) | |
Media_Stream_Handler_Transport | Struct | (usuussduss) | |
Media_Stream_Handler_Codec | Struct | (usuuua{ss}) | |
RTCP_Feedback_Message_Properties | Struct | (ua(sss)) | |
RTCP_Feedback_Message | Struct | (sss) | |
RTP_Header_Extension | Struct | (uuss) |
Description
Methods
CodecChoice (u: Codec_ID) → nothing
Parameters
- Codec_ID — u
Error (u: Error_Code, s: Message) → nothing
Parameters
- Error_Code — u (Media_Stream_Error)
- Message — s
NativeCandidatesPrepared () → nothing
NewActiveCandidatePair (s: Native_Candidate_ID, s: Remote_Candidate_ID) → nothing
Parameters
- Native_Candidate_ID — s
- Remote_Candidate_ID — s
NewActiveTransportPair (s: Native_Candidate_ID, (usuussduss): Native_Transport, s: Remote_Candidate_ID, (usuussduss): Remote_Transport) → nothing
Parameters
- Native_Candidate_ID — s
- Native_Transport — (usuussduss) (Media_Stream_Handler_Transport)
- Remote_Candidate_ID — s
- Remote_Transport — (usuussduss) (Media_Stream_Handler_Transport)
Informs the connection manager that a valid transport pair has been discovered and streaming is in progress. Component id MUST be the same for both transports and the pair is only valid for that component.
Rationale:
The connection manager might need to send the details of the active transport pair (e.g. c and o parameters of SDP body need to contain address of selected native RTP transport as stipulated by RFC 5245). However, the candidate ID might not be enough to determine these info if the transport was found after NativeCandidatesPrepared has been called (e.g. peer reflexive ICE candidate).
This method must be called before NewActiveCandidatePair.
Rationale:
This way, connection managers supporting this method can safely ignore subsequent NewActiveCandidatePair call.
Connection managers SHOULD NOT implement this method unless they need to inform the peer about selected transports. As a result, streaming implementations MUST NOT treat errors raised by this method as fatal.
Rationale:
Usually, connection managers only need to do one answer/offer round-trip. However, some protocols give the possibility to to send an updated offer (e.g. ICE defines such mechanism to avoid some race conditions and to properly set the state of gateway devices).
NewNativeCandidate (s: Candidate_ID, a(usuussduss): Transports) → nothing
Parameters
- Candidate_ID — s
- Transports — a(usuussduss) (Media_Stream_Handler_Transport_List)
- component number
- IP address (as a string)
- port
- base network protocol (one of the values of MediaStreamBaseProto)
- proto subtype (e.g. RTP)
- proto profile (e.g. AVP)
- our preference value of this transport (double in range 0.0-1.0 inclusive); 1 signals the most preferred transport
- transport type, one of the values of MediaStreamTransportType
- username if authentication is required
- password if authentication is required
Ready (a(usuuua{ss}): Codecs) → nothing
Parameters
- Codecs — a(usuuua{ss}) (Media_Stream_Handler_Codec_List)
SetLocalCodecs (a(usuuua{ss}): Codecs) → nothing
Parameters
- Codecs — a(usuuua{ss}) (Media_Stream_Handler_Codec_List)
Used to provide codecs after Ready(), so the media client can go ready for an incoming call and exchange candidates/codecs before knowing what local codecs are available.
This is useful for gatewaying calls between two connection managers. Given an incoming call, you need to call Ready to get the remote codecs before you can use them as the "local" codecs to place the outgoing call, and hence receive the outgoing call's remote codecs to use as the incoming call's "local" codecs.
In this situation, you would pass an empty list of codecs to the incoming call's Ready method, then later call SetLocalCodecs on the incoming call in order to respond to the offer.
StreamState (u: State) → nothing
Parameters
- State — u (Media_Stream_State)
SupportedCodecs (a(usuuua{ss}): Codecs) → nothing
Parameters
- Codecs — a(usuuua{ss}) (Media_Stream_Handler_Codec_List)
CodecsUpdated (a(usuuua{ss}): Codecs) → nothing
Parameters
- Codecs — a(usuuua{ss}) (Media_Stream_Handler_Codec_List)
Rationale:
HoldState (b: Held) → nothing
Parameters
- Held — b
UnholdFailure () → nothing
SupportedFeedbackMessages (a{u(ua(sss))}: Messages) → nothing
Parameters
- Messages — a{u(ua(sss))} (RTCP_Feedback_Message_Map)
SupportedHeaderExtensions (a(uuss): Header_Extensions) → nothing
Parameters
- Header_Extensions — a(uuss) (RTP_Header_Extensions_List)
Signals
AddRemoteCandidate (s: Candidate_ID, a(usuussduss): Transports)
Parameters
- Candidate_ID — s
- Transports — a(usuussduss) (Media_Stream_Handler_Transport_List)
RemoveRemoteCandidate (s: Candidate_ID)
Parameters
- Candidate_ID — s
Rationale:
SetActiveCandidatePair (s: Native_Candidate_ID, s: Remote_Candidate_ID)
Parameters
- Native_Candidate_ID — s
- Remote_Candidate_ID — s
SetRemoteCandidateList (a(sa(usuussduss)): Remote_Candidates)
Parameters
- Remote_Candidates — a(sa(usuussduss)) (Media_Stream_Handler_Candidate_List)
SetRemoteCodecs (a(usuuua{ss}): Codecs)
Parameters
- Codecs — a(usuuua{ss}) (Media_Stream_Handler_Codec_List)
SetStreamPlaying (b: Playing)
Parameters
- Playing — b
Rationale:
SetStreamSending (b: Sending)
Parameters
- Sending — b
StartTelephonyEvent (y: Event)
Parameters
- Event — y (DTMF_Event)
StartNamedTelephonyEvent (y: Event, u: Codec_ID)
Parameters
- Event — y (DTMF_Event)
- Codec_ID — u
StartSoundTelephonyEvent (y: Event)
Parameters
- Event — y (DTMF_Event)
StopTelephonyEvent ()
SetStreamHeld (b: Held)
Parameters
- Held — b
Emitted when the connection manager wishes to place the stream on hold (so the streaming client should free hardware or software resources) or take the stream off hold (so the streaming client should reacquire the necessary resources).
When placing a channel's streams on hold, the connection manager SHOULD notify the remote contact that this will be done (if appropriate in the protocol) before it emits this signal.
Rationale:
It is assumed that relinquishing a resource will not fail. If it does, the call is probably doomed anyway.
When unholding a channel's streams, the connection manager SHOULD emit this signal and wait for success to be indicated via HoldState before it notifies the remote contact that the channel has been taken off hold.
Rationale:
This means that if a resource is unavailable, the remote contact will never even be told that we tried to acquire it.
SetRemoteFeedbackMessages (a{u(ua(sss))}: Messages)
Parameters
- Messages — a{u(ua(sss))} (RTCP_Feedback_Message_Map)
SetRemoteHeaderExtensions (a(uuss): Header_Extensions)
Parameters
- Header_Extensions — a(uuss) (RTP_Header_Extensions_List)
Properties
STUNServers — a(sq) (Socket_Address_IP_List)
Rationale:
CreatedLocally — b
Rationale:
NATTraversal — s
The transport (NAT traversal technique) to be used for this stream. Well-known values include:
- none
- Raw UDP, with or without STUN, should be used. If the STUNServers property is non-empty, STUN SHOULD be used.
- stun
- A deprecated synonym for 'none'.
- gtalk-p2p
- Google Talk peer-to-peer connectivity establishment should be used, as implemented in libjingle 0.3.
- ice-udp
- Interactive Connectivity Establishment should be used, as defined by the IETF MMUSIC working group.
- wlm-8.5
- The transport used by Windows Live Messenger 8.5 or later, which resembles ICE draft 6, should be used.
- wlm-2009
- The transport used by Windows Live Messenger 2009 or later, which resembles ICE draft 19, should be used.
This property cannot change once the stream has been created, so there is no change notification.
RelayInfo — aa{sv} (String_Variant_Map_List)
A list of mappings describing TURN or Google relay servers available for the client to use in its candidate gathering, as determined from the protocol. Map keys are:
ip
- s- The IP address of the relay server as a dotted-quad IPv4
address literal or an RFC2373 IPv6 address literal. This MUST NOT
be a DNS hostname.
Rationale:
High-quality connection managers already need an asynchronous DNS resolver, so they might as well resolve this name to an IP and make life easier for streaming implementations. type
- s-
Either
udp
for UDP (UDP MUST be assumed if this key is omitted),tcp
for TCP, ortls
.The precise meaning of this key depends on the NATTraversal property: if NATTraversal is
ice-udp
,tls
means TLS over TCP as referenced by ICE draft 19, and if NATTraversal isgtalk-p2p
,tls
means a fake SSL session over TCP as implemented by libjingle. port
- q- The UDP or TCP port of the relay server as an ASCII unsigned integer
username
- s- The username to use
password
- s- The password to use
component
- u- The component number to use this relay server for, as an
ASCII unsigned integer; if not included, this relay server
may be used for any or all components.
Rationale:
In ICE draft 6, as used by Google Talk, credentials are only valid once, so each component needs relaying separately.
Rationale:
An equivalent of the gtalk-p2p-relay-token property on MediaSignalling channels is not included here. The connection manager should be responsible for making the necessary HTTP requests to turn the token into a username and password.
The type of relay server that this represents depends on the value of the NATTraversal property. If NATTraversal is ice-udp, this is a TURN server; if NATTraversal is gtalk-p2p, this is a Google relay server; otherwise, the meaning of RelayInfo is undefined.
If relaying is not possible for this stream, the list is empty.
This property cannot change once the stream has been created, so there is no change notification.
Types
Media_Stream_Error — u
- Unknown (0)
- EOS (1)
- Codec_Negotiation_Failed (2)
- Connection_Failed (3)
- Network_Error (4)
- No_Codecs (5)
- Invalid_CM_Behavior (6)
- Media_Error (7)
Media_Stream_Base_Proto — u
- UDP (0)
- TCP (1)
Media_Stream_Transport_Type — u
- Local (0)
- Derived (1)
- Relay (2)
RTCP_Feedback_Message_Map — a{u(ua(sss))}
- Codec_Identifier — u
- Properties — (ua(sss)) (RTCP_Feedback_Message_Properties)
Media_Stream_Handler_Candidate — (sa(usuussduss))
- Name — s
- Transports — a(usuussduss) (Media_Stream_Handler_Transport_List)
Media_Stream_Handler_Transport — (usuussduss)
- Component_Number — u
- IP_Address — s
- Port — u
- Protocol — u (Media_Stream_Base_Proto)
- Subtype — s
- Profile — s
- Preference_Value — d
- Transport_Type — u (Media_Stream_Transport_Type)
- Username — s
- Password — s
Media_Stream_Handler_Codec — (usuuua{ss})
- Codec_ID — u
- Name — s
- Media_Type — u (Media_Stream_Type)
- Clock_Rate — u
- Number_Of_Channels — u
- Parameters — a{ss} (String_String_Map)
RTCP_Feedback_Message_Properties — (ua(sss))
- RTCPMinimumInterval — u
- Messages — a(sss) (RTCP_Feedback_Message_List)
RTCP_Feedback_Message — (sss)
- Type — s
- Subtype — s
- Parameters — s
RTP_Header_Extension — (uuss)
- ID — u
- Direction — u (Media_Stream_Direction)
- URI — s
- Parameters — s