TcpSocket.receive

Receive a formatted packet of data from the remote peer.

In blocking mode, this function will wait until the whole packet has been received. This function will fail if the socket is not connected.

  1. Status receive(void[] data, size_t sizeReceived)
  2. Status receive(Packet packet)
    class TcpSocket
    Status
    receive

Parameters

packet Packet

Packet to fill with the received data

Return Value

Type: Status

Status code.

Meta