TipcSrvMonServerNamesGetWatch determine if this RTclient is watching RTserver names
T_BOOL TipcSrvMonServerNamesGetWatch(srv
,watch_status_return
) T_IPC_SRVsrv
; T_BOOL *watch_status_return
;
srv
connection handle to RTserver
watch_status_return
storage for watch status
TRUE
if the RTserver names watch status was successfully retrieved, FALSE
otherwise.
If TipcSrvMonServerNamesGetWatch fails, it returns FALSE
and sets the global SmartSockets error number to:
TipcSrvMonServerNamesGetWatch determines whether this RTclient is watching the RTserver names that match the value of the Monitor_Scope option. The watch status controls whether the RTclient receives a MON_SERVER_NAMES_STATUS message each time an RTserver is created or destroyed. An RTserver is considered created when it starts up (and usually connects to other RTservers). An RTserver is considered destroyed when it terminates or disconnects from other RTservers.
Each MON_SERVER_NAMES_STATUS message contains four fields:
"
ident
:
user
@
node
"
(for example, "Primary_RTclient: ssuser@workstation1"
)""
if not applicable) ""
if not applicable)To set whether this RTclient is watching RTserver names, use TipcSrvMonServerNamesSetWatch. To poll once for RTserver names, use TipcSrvMonServerNamesPoll.
If TipcSrvMonServerNamesGetWatch returns FALSE
, it does not store a value in watch_status_return
.
TipcSrvMonServerNamesPoll, TipcSrvMonServerNamesSetWatch
This example uses TipcSrvMonServerNamesGetWatch to get the status of watching RTserver names:
T_BOOL watch_status; if (!TipcSrvMonServerNamesGetWatch(srv, &watch_status)) {
return
; /* error */
} TutOut("This process is %s RTserver names.\n", watch_status ? "watching" : "not watching");
TIBCO SmartSockets™ Application Programming Interface Software Release 6.8, July 2006 Copyright © TIBCO Software Inc. All rights reserved www.tibco.com |