Add an event listener for one of the handler types.
The handler being assigned.
The event listener to add.
Close the WebSocket connection.
Optionalcode: numberOptionalreason: stringOpens a WebSocket connection to the URL with the given protocols.
URL to connect to
Protocols to send when establishing the connection
OptionalisSignedUrl: booleanwhether the URL is signed
Destroys internal reference to the WebSocket.
Remove an event listener for one of the handler types.
The handler being assigned.
The event listener to add.
Sends a raw byte message.
byte or string message to send
Whether the data was queued for sending
Adapter for WebSocket implementations