Receives data from a bound socket, according to specified flags, and places the data in a buffer array.

Namespace: GHIElectronics.NETMF.Net.Sockets
Assembly: GHIElectronics.NETMF.W5100 (in GHIElectronics.NETMF.W5100.dll) Version: 4.1.9.0 (4.1.9.0)

Syntax

C#
public int Receive(
	byte[] buffer,
	int size,
	SocketFlags socketFlags
)

Parameters

buffer
Type: array<System..::..Byte>[]()[][]
An array in which the received data is placed.
size
Type: System..::..Int32
The size of the buffer array, in bytes. If the number of bytes received is greater than the size of the buffer array, the data is truncated so that it fits in the array.
socketFlags
Type: GHIElectronics.NETMF.Net.Sockets..::..SocketFlags
Ignored.

Return Value

The number of bytes received, if the call was successful; otherwise, -1.

See Also