WebSocket
WebSocket.Send
Sends a Lua string with a WebSocket object returned by WebSocket.connect. The method expects the WebSocket table as the first argument and the message string as the second argument. It reads the object’s connection state, raises “WebSocket state is missing” if that object is absent, returns without sending when the state is destroyed or closed, and calls curl_ws_send with CURLWS_TEXT by default or CURLWS_BINARY when the optional third argument is a boolean true. It returns no values and does not report the number of bytes sent.
Sends a Lua string with a WebSocket object returned by WebSocket.connect. The method expects the WebSocket table as the first argument and the message string as the second argument. It reads the object’s connection state, raises “WebSocket state is missing” if that object is absent, returns without sending when the state is destroyed or closed, and calls curl_ws_send with CURLWS_TEXT by default or CURLWS_BINARY when the optional third argument is a boolean true. It returns no values and does not report the number of bytes sent.