TipcSrvRead


Name

TipcSrvRead — read all available data from the connection to RTserver and queue messages in priority order

Synopsis

T_BOOL TipcSrvRead(timeout) 
T_REAL8 timeout; 

Arguments

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 TipcSrvRead fails, it returns FALSE and sets the global SmartSockets error number to one of:

Description

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

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

Caution

TipcSrvRead is a low-level function that is normally not used directly by developers; TipcSrvRead is normally called only by TipcSrvMsgNext and TipcSrvMsgSearch.

See Also

TipcConnRead, TipcSrvCheck, TipcSrvReadCbCreate

Examples

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

if (!TipcSrvRead(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