Zen API
 All Classes Files Functions Variables Typedefs Friends Macros Modules Pages
kStatus kUdpClient_SetWriteBuffers ( kUdpClient  client,
kSSize  socketSize,
kSSize  clientSize 
)

Sets the size of write buffers.

Socket buffers decouple the sender and receiver, so that the sender does not need to block while waiting for the receiver to receive all bytes. Client buffers enable the sender to formulate a datagram over multiple writes, rather than supplying the entire datagram in a single write call.

If the client buffer size is greater than zero, use the kUdpClient_Send method to send the datagram when writing is complete. If the client buffer size is zero, a datagram can be sent immediately (without buffering) using kUdpClient_WriteTo.

By default, the client buffer size is zero and the socket buffer size is determined by the underlying operating system.

Parameters
clientUDP client object.
socketSizeSize of the write buffer maintained by the underlying socket (-1 to leave unchanged).
clientSizeSize of the write buffer maintained by the client object (-1 to leave unchanged).
Returns
Operation status.