TipcSrvConnRead


Name

TipcSrvConnRead — read all available data from the connection and queue messages in priority order

Synopsis

T_BOOL TipcSrvConnRead(srv, timeout) 
T_IPC_SRV srv; 
T_REAL8 timeout; 

Arguments

srv — connection handle to RTserver

timeout — maximum number of seconds to wait for data to arrive

Return Values

TRUE if data was successfully read from the connection to RTserver, FALSE otherwise.

Diagnostics

If TipcSrvConnRead fails, it returns FALSE and sets the global SmartSockets error number to one of:

Description

TipcSrvConnRead reads and queues all available messages from the connection to RTserver by calling TipcConnRead. See TipcConnRead for more information on reading data from a connection.

TipcSrvConnRead may attempt to automatically create a connection to RTserver. If RTclient has a warm connection to RTserver, TipcSrvConnRead sleeps for timeout seconds and returns FALSE. See TipcSrvConnOpen for more information on automatic creation of connections and warm connections to RTserver.

Caution

TipcSrvConnRead is a low-level function that is normally not used directly by developers; TipcSrvConnRead is normally called only by TipcSrvConnMsgNext and TipcSrvConnMsgSearch.

See Also

TipcConnRead, TipcSrvConnCheck, TipcSrvConnReadCbCreate

Examples

This example reads all data that is immediately available from the connection to RTserver with TipcSrvConnRead:

if (!TipcSrvConnRead(srv, 0.0)) { 
  return;  /* error */ 
}  

TIBCO SmartSockets™ Application Programming Interface
Software Release 6.8, July 2006
Copyright © TIBCO Software Inc. All rights reserved
www.tibco.com