new WindowSocket(_windowopt)
- Source:
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
_window |
Window |
<optional> |
specify other window to listen |
Classes
Methods
(static) broadcast(…args) → {WindowSocket}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
args |
Array.<any> |
<repeatable> |
Returns:
- Type
- WindowSocket
(static) clients() → {Array.<WindowSocket.Client>}
Returns:
- Type
- Array.<WindowSocket.Client>
(static) encoders() → {Array.<WindowSocket.Encoder>}
get current encoders
Returns:
- Type
- Array.<WindowSocket.Encoder>
(static) encoders(encoders) → {WindowSocket}
update encoders
Parameters:
Name | Type | Description |
---|---|---|
encoders |
Array.<WindowSocket.Encoder> |
Returns:
- Type
- WindowSocket
(static) fire(…args) → {WindowSocket}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
args |
Array.<any> |
<repeatable> |
Returns:
- Type
- WindowSocket
(static) start() → {WindowSocket}
Returns:
- Type
- WindowSocket
(static) stop() → {WindowSocket}
Returns:
- Type
- WindowSocket
(static) validateSource(event) → {WindowSocket.Client}
Validate Message Event Source
Parameters:
Name | Type | Description |
---|---|---|
event |
MessageEvent |
Returns:
- Type
- WindowSocket.Client
Events
connect
Parameters:
Type | Description |
---|---|
WindowSocket.Client |
message
Type:
- object
message:error
Type:
- MessageEvent
message:raw
Type:
- MessageEvent