send method

void send(
  1. OpCode code,
  2. Uint8List data
)

Implementation

void send(OpCode code, Uint8List data) {
  var frame = WebSocketFrame(code, mask: mask, payload: data);
  var raw = frame.rawBytes();
  socket.add(raw.toList());
}