TipcMsgSetCorrelationId


Name

TipcMsgSetCorrelationId — set the correlation identifier property of a message

Synopsis

T_BOOL TipcMsgSetCorrelationId(msg, correlation_id) 
T_IPC_MSG msg; 
T_STR correlation_id; 

Arguments

msg — message to generate identifier for

correlation_id — message correlation identifier

Return Values

TRUE if the identifier was successfully set for the message, FALSE otherwise.

Diagnostics

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

Description

TipcMsgSetCorrelationId sets the correlation identifier property of a message. The correlation identifier property is a string whose meaning depends on how the message is being used. Applications of messages are free to use the correlation identifier for any purpose.

Caution

None

See Also

TipcMsgGetCorrelationId, TipcMsgGenerateMessageId, TipcMsgGetMessageId

Examples

This example sets the correlation identifier property of a message to the message identifier property of another message:

T_STR id; 
if (!TipcMsgGetMessageId(request_msg, &id)) { 
  return;  /* error */ 
} 
if (!TipcMsgSetCorrelationId(reply_msg, id)) { 
  return;  /* error */ 
} 

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