RTCPeerConnectionIceEvent()
Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
The RTCPeerConnectionIceEvent() constructor creates a new RTCPeerConnectionIceEvent.
Syntax
var event = new RTCPeerConnectionIceEvent(type, options);
Parameters
type-
Is a
DOMStringcontaining the name of the event, like"icecandidate". options-
A dictionary of type
RTCPeerConnectionInit, which may contain one or more of the following fields:-
"candidate"(optional, default isnull): ARTCIceCandidaterepresenting the ICE candidate being concerned by the event. Ifnull, the event indicates the end of candidate gathering. -
"url"(optional, default isnull): The URL of the STUN or TURN server which was used to gather the candidate. If the candidate was not gathered by a STUN or TURN server, this value must benull. -
"bubbles"(optional, default isfalse): Inherited fromEventInit(), this Boolean option indicates whether or not the event must bubble. -
"cancelable"(optional, default isfalse, inherited fromEventInit(), this Boolean indicates whether or not the event can be canceled.
-
Return value
A newly-created RTCPeerConnectionIceEvent, configured as specified in the provided options.
Specifications
| Specification |
|---|
| WebRTC 1.0: Real-Time Communication Between Browsers (WebRTC 1.0) # dom-rtcpeerconnectioniceevent-constructor |
Browser compatibility
| Desktop | Mobile | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | WebView Android | Chrome Android | Firefox for Android | Opera Android | Safari on IOS | Samsung Internet | |
RTCPeerConnectionIceEvent |
56 |
15 |
24 |
No |
Yes |
12 |
56 |
56 |
24 |
Yes |
12 |
6.0 |
See also
- WebRTC
- Its usual target:
RTCPeerConnection.
© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnectionIceEvent/RTCPeerConnectionIceEvent