Content:
- Methods

WebSocket are useful when constantly comminicating with a server and when a fast reaction time is required.

wbs = app.CreateWebSocket( ip, id, retry, options ) → app object: WebSocket

A web socket will automatically open after creating it. Once after finished loading, the OnOpen callback is called.

In order to receive messages from the server you have to specify a OnMessage callback.

See Also: CreateWebServer

Example - Basic click to expand contents 

Methods

The following methods are available on the WebSocket object:

Close()
GetSocket() → JavaScript object: WebSocket
IsOpen() → Boolean