send method

dynamic send(
  1. dynamic data
)

Sends a message through the WebSocket connection.

The data parameter represents the message to be sent through the WebSocket.

Implementation

send(data) {
  if (_socket != null) {
    _socket?.add(data);
  }
}