TipcSrvConnSubjectSetSubscribeEx


Name

TipcSrvConnSubjectSetSubscribeEx — start or stop subscribing to a subject using extended options

Synopsis

T_BOOL TipcSrvConnSubjectSetSubscribeEx(srv, subj_name, status, type, 
flags, type_specific_struct) 
T_IPC_SRV srv; 
T_STR subj_name; 
T_BOOL status; 
T_INT4 type; 
T_INT4 flags; 
T_PTR type_specific_struct; 

Arguments

srv — connection handle to RTserver

subj_name — name of the subject to set subscribe status for

status — subscribe status (TRUE to subscribe or FALSE to unsubscribe)

type — type of subscribe to use (T_SUBJ_NONE for a normal subscribe or T_SUBJ_CACHE to enable the SmartSockets Cache interface)

flags — describe the attribute of type

type_specific_struct — used to pass any additional information needed by a type

Return Values

TRUE if the subscribe status of the subject was successfully set, FALSE otherwise.

Diagnostics

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

Description

TipcSrvConnSubjectSetSubscribeEx is used to subscribe to a subject using extended options. Currently the only option available is caching.

If type is T_SUBJ_NONE, flags must be set to zero (0).

If type is T_SUBJ_CACHE, flags must be one of:

If type is either T_SUBJ_NONE or T_SUBJ_CACHE, type_specific_struct must be set to T_NULL.

Caution

None

See Also

None

Examples

This example retrieves a message from SmartSockets Cache

/* Retrieve message from Cache */ 
TutOut("Retrieving messages from Cache ...\n"); 
 
TipcSrvConnSubjectSetSubscribeEx( 
  srv,                          /* requested server object */ 
  "/SCache/*",                  /* requested subject */ 
  T_TRUE,                       /* true to subscribe */ 
  T_SUBJ_CACHE,                 /* type of subscribe */ 
  T_SUBJ_FLAG_SC_INITIAL_LOAD,  /* attribute type to last value */ 
  T_NULL);                      /* as using T_SUBJ_CACHE */ 

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