fune/servo/components/script/dom/webidls/WebSocket.webidl
Hinali Marfatia fafec6e841 servo: Merge #4096 - Adding a new webidl and websocket.rs file (from servo:websocket); r=Ms2ger
Closes #3813.

Source-Repo: https://github.com/servo/servo
Source-Revision: 62edb842c7d89f2349c4c030139cbf5a927d1eb1
2014-11-25 07:45:42 -07:00

27 lines
1,005 B
Text

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
[Constructor(DOMString url)]
interface WebSocket : EventTarget {
readonly attribute DOMString url;
//attribute DOMString port;
//attribute DOMString host;
//ready state
const unsigned short CONNECTING = 0;
const unsigned short OPEN = 1;
const unsigned short CLOSING = 2;
const unsigned short CLOSED = 3;
//readonly attribute unsigned short readyState;
//readonly attribute unsigned long bufferedAmount;
//networking
//attribute EventHandler onopen;
//attribute EventHandler onerror;
//attribute EventHandler onclose;
//readonly attribute DOMString extensions;
//readonly attribute DOMString protocol;
//void send(USVString data);
//void send(Blob data);
//void send(ArrayBuffer data);
//void send(ArrayBufferView data);
};