Class Protocols.WebSocket.Port

Inheritance graph
Protocols.HTTP.Server.Port Protocols.WebSocket.Port
Description

Creates a simple HTTP Server. ws_cb will be called for all incoming WebSocket connections. Its first argument are the list of protocols requested by the client and the second argument the corresponding Request object. The WebSocket connection handshake is completed by calling Request.websocket_accept. http_cb will be called for all other HTTP Requests or if ws_cb is zero.

See also

Protocols.HTTP.Server.Port


Inherit Port

inherit Protocols.HTTP.Server.Port : Port


Method create

Protocols.WebSocket.Port Protocols.WebSocket.Port(function(Protocols.HTTP.Server.Request:void) http_cb, function(array(string), Request:void)|void ws_cb, void|int portno, void|string interface)