W3cubDocs

/DOM

RTCPeerConnectionIceEvent

This is an experimental technology
Check the Browser compatibility table carefully before using this in production.

The RTCPeerConnectionIceEvent interface represents events that occurs in relation to ICE candidates with the target, usually an RTCPeerConnection. Only one event is of this type: icecandidate.

Properties

A RTCPeerConnectionIceEvent being an Event, this event also implements these properties.

RTCPeerConnectionIceEvent.candidate Read only
Contains the RTCIceCandidate containing the candidate associated with the event.

Constructors

RTCPeerConnectionIceEvent()
Returns a new RTCPeerConnectionIceEvent. It takes two parameters, the first being a DOMString representing the type of the event; the second a dictionary containing the RTCIceCandidate it refers to.

Methods

A RTCPeerConnectionIceEvent being an Event, this event also implements these properties. There is no specific RTCDataChannelEvent method.

Examples

pc.onicecandidate = function( ev ) {
  alert("The ICE candidate (transport address: '" + 
    ev.candidate.candidate + 
    "') has been added to this connection.");
}

Specifications

Browser compatibilityUpdate compatibility data on GitHub

Desktop
Chrome Edge Firefox Internet Explorer Opera Safari
Basic support ? — 56
? — 56
Uses the non-standard name: RTCIceCandidateEvent
56
Yes Yes ? Yes ?
candidate 56 15 Yes ? Yes ?
RTCPeerConnectionIceEvent() constructor. 56 Yes Yes ? Yes ?
url ? ? ? ? ? ?
Mobile
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support ? — 56
? — 56
Uses the non-standard name: RTCIceCandidateEvent
56
? — 56
? — 56
Uses the non-standard name: RTCIceCandidateEvent
56
? Yes Yes ? 6.0
candidate 56 56 ? Yes Yes ? 6.0
RTCPeerConnectionIceEvent() constructor. 56 56 ? Yes Yes ? 6.0
url ? ? ? ? ? ? ?

See also

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnectionIceEvent