TipcSrvConnQueueCbLookup look up a queue callback in the connection
T_CB TipcSrvConnQueueCbLookup(srv
,mt
,func
,arg
) T_IPC_SRVsrv
; T_IPC_MTmt
; T_IPC_CONN_QUEUE_CB_FUNCfunc
; T_CB_ARGarg
;
srv
connection handle to RTserver
mt
message type to look up callback for (null means global callback)
func
callback function
arg
user-defined argument
New callback if successful, NULL
otherwise.
If TipcSrvConnQueueCbLookup fails, it returns NULL
and sets the global SmartSockets error number to one of:
TipcSrvConnQueueCbLookup looks up a queue callback with the desired message type, function, and argument in the connection to RTserver by calling TipcConnQueueCbLookup. These callbacks are called when a message is inserted into or deleted from the message queue of the connection to RTserver. See TipcConnQueueCbCreate for more information on connection queue callbacks.
TipcSrvConnQueueCbLookup may attempt to automatically create a connection to RTserver. If RTclient has a warm connection to RTserver, TipcSrvConnQueueCbLookup looks up a queue callback in the warm connection. See TipcSrvConnOpen for more information on automatic creation of connections and warm connections to RTserver.
None
TipcConnQueueCbCreate, TipcSrvConnQueueCbCreate, TipcConnQueueCbLookup; see the TIBCO SmartSockets Utilities for information on TutCbDestroy.
This example looks up and destroys a NUMERIC_DATA queue callback in the connection to RTserver:
T_CB cb; T_IPC_MT mt; mt = TipcMtLookupByNum(T_MT_NUMERIC_DATA); if (mt == NULL) {return
; /* error */
} cb = TipcSrvConnQueueCbLookup(srv, mt, my_numeric_queue_cb, NULL); if (cb == NULL) {return
; /* error */
} if (!TutCbDestroy(cb)) {return
; /* error */
}
TIBCO SmartSockets™ Application Programming Interface Software Release 6.8, July 2006 Copyright © TIBCO Software Inc. All rights reserved www.tibco.com |