blob: 89a2a696071e2ae7d5a4d796e1899fccd1fadc8c [file] [log] [blame]
// Copyright 2018 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// https://w3c.github.io/webrtc-quic/#dom-rtcquictransportstate
enum RTCQuicTransportState {
"new",
"connecting",
"connected",
"closed",
"failed",
};
// https://w3c.github.io/webrtc-quic/#quic-transport*
[
Constructor(RTCIceTransport transport, sequence<RTCCertificate> certificates),
ConstructorCallWith=ExecutionContext,
RaisesException=Constructor,
Exposed=Window,
RuntimeEnabled=RTCQuicTransport
] interface RTCQuicTransport : EventTarget {
readonly attribute RTCIceTransport transport;
readonly attribute RTCQuicTransportState state;
RTCQuicParameters getLocalParameters();
RTCQuicParameters? getRemoteParameters();
sequence<RTCCertificate> getCertificates();
sequence<ArrayBuffer> getRemoteCertificates();
[RaisesException] void start(RTCQuicParameters remoteParameters);
void stop();
[RaisesException] RTCQuicStream createStream();
attribute EventHandler onstatechange;
attribute EventHandler onerror;
attribute EventHandler onquicstream;
};