RTCPeerConnectionIceEvent()

RTCPeerConnectionIceEvent() コンストラクターは、新しい RTCPeerConnectionIceEvent オブジェクトを作成します。

構文

js
new RTCPeerConnectionIceEvent(type, options)

引数

type

文字列で、このイベントの名前です。 大文字小文字を区別し、ブラウザーは常に icecandidate に設定します。

options 省略可

オブジェクトで、Event() で定義されているプロパティに加えて、以下のプロパティがあります。

candidate

RTCIceCandidate で、そのイベントが関係する ICE の候補を表します。 もし null ならば、そのイベントは候補の収集の終わりを示します。

url

文字列で、候補を収集するために使用された STUN または TURN サーバーの URL を保持します。 もし候補が STUN または TURN サーバーによって収集されていない場合、この値は null でなければならず、またこれは既定値です。

返値

提供されたオプションを指定して構成された、新しい RTCPeerConnectionIceEvent オブジェクト。

仕様書

Specification
WebRTC: Real-Time Communication in Browsers
# dom-rtcpeerconnectioniceevent-constructor

ブラウザーの互換性

BCD tables only load in the browser

関連情報