Conn
One open socket, as the hub sees it.
Methods
Section titled “Methods”buffered()
Section titled “buffered()”buffered():
number
bytes queued and not yet written to the network
Returns
Section titled “Returns”number
close()
Section titled “close()”close(
code,reason):void
Parameters
Section titled “Parameters”number
reason
Section titled “reason”string
Returns
Section titled “Returns”void
send()
Section titled “send()”send(
data):void
Parameters
Section titled “Parameters”string
Returns
Section titled “Returns”void
sendBytes()?
Section titled “sendBytes()?”
optionalsendBytes(data):void
Optional: the same kind of message already encoded as UTF-8, to go out as a text frame (ws: send(data, { binary: false })). The hub
encodes each room frame once and hands every reader the same bytes; without this it calls send(text) per reader.
Parameters
Section titled “Parameters”Uint8Array
Returns
Section titled “Returns”void