Serial Framework C++ Edition

◆ OnData()

__event void OnData ( void *  Sender,
CwclServerClientDataConnection *const  Client,
const void *const  Data,
const unsigned long  Size 
)

The event fires when new data is received from the connected remote device.

Parameters
SenderThe object that initiated the event.
ClientA CwclServerClientDataConnection object represents a remote client connection.
DataThe pointer to the received data buffer. It is guaranteed that the parameter points to a valid data buffer. The data buffer is valid only inside the event handler. If an application needs to use the data outside the event handle it must allocate own buffer and copy data into it.
SizeThe data buffer size. It is guaranteed that the size is greater than 0.
See also
CwclServerClientDataConnection