TipcSrvConnCheck check if data can be read from or written to the connection
T_BOOL TipcSrvConnCheck(srv
,check_mode
,timeout
) T_IPC_SRVsrv
; T_IO_CHECK_MODEcheck_mode
; T_REAL8timeout
;
srv
connection handle to RTserver
check_mode
how to check RTserver availability
timeout
maximum number of seconds to wait for availability
TRUE
if data can be read or written, FALSE
if timeout
reached or an error occurred.
If TipcSrvConnCheck fails, it returns FALSE
and sets the global SmartSockets error number to one of:
TipcSrvConnCheck checks the connection to RTserver by calling TipcConnCheck. The connection can be checked if data can be read (check_mode
is T_IO_CHECK_READ
) or if data can be written (check_mode
is T_IO_CHECK_WRITE
). See TipcConnCheck for more information on checking connections.
TipcSrvConnCheck may attempt to automatically create a connection to RTserver. If RTclient has a warm connection to RTserver, TipcSrvConnCheck sleeps for timeout
seconds and returns FALSE
. See TipcSrvConnRead on automatic creation of connections and warm connections to RTserver.
TipcSrvConnCheck is a low-level function that is normally not used directly by developers. TipcConnCheck is normally called only by TipcSrvConnFlush and TipcSrvConnRead.
TipcConnCheck, TipcSrvConnRead
This example uses TipcSrvConnCheck to check if data is available within 3.4 seconds for reading from the connection to RTserver:
TIBCO SmartSockets™ Application Programming Interface Software Release 6.8, July 2006 Copyright © TIBCO Software Inc. All rights reserved www.tibco.com |