BOOL IsWritable( |
|
INT nTimeout |
|
); |
The IsWritable method is used to determine if data can be
written to the remote host.
Parameters
- nTimeout
- Timeout for remote host response, in seconds. A value of zero
specifies that the connection should be polled without blocking the
current thread.
Return Value
If data can be sent to the client within the specified timeout
period, the method returns a non-zero value. The method will return
zero if the socket send buffer is full.
Remarks
The IsWritable method cannot be used to determine the
amount of data that can be sent to the client without blocking the
current thread. A non-zero return value only indicates that the send
buffer is not full and can accept some data. In
most cases, it is recommended that larger blocks of data be broken
into smaller logical blocks rather than attempting to send it all of
the data at once. For very large streams of data, it is recommended
that you use the WriteStream method.
Requirements
Minimum Desktop Platform: Windows 7 (Service Pack 1)
Minimum Server Platform: Windows Server 2008 R2 (Service Pack 1)
Header: Include cswsock10.h
Import Library: cswskv10.lib
See Also
IsReadable,
Write,
WriteLine,
WriteStream
|