Add Nested Message

Convenience Function

Declaration

tibrv_status tibrvMsg_AddMsg(
   tibrvMsg       message,
   const char*    fieldName,
   tibrvMsg       value);
tibrv_status tibrvMsg_AddMsgEx(
   tibrvMsg       message,
   const char*    fieldName,
   tibrvMsg       value,
   tibrv_u16      fieldId);

Purpose

Add a field containing a nested submessage.

Remarks

This function adds only the data portion of the nested message (value); it does not include any address information or certified delivery information.

Parameter

Description

message

Add the new field to this message.

fieldName

Create the new field with this name.

value

Add a new field that contains this submessage.

The function copies the data into the new field.

fieldId

Create the new field with this identifier. Zero is a special value that signifies no field identifier. All non-zero field identifiers must be unique within each message.

It is illegal to add a field that has both a NULL field name, and a non-zero field identifier.