WebSphere Message Brokers
File: as07670_
Writer: Lorraine Waitt

Reference topic

This build: July 31, 2007 21:37:23

cniWriteBuffer

Writes the syntax element tree associated with the specified message to the data buffer owned by that message object. This function is typically used by output nodes. This operation serializes the element tree into a bit stream that can then be processed as a sequence of contiguous bytes. This function should be used when writing the bit stream to a target that is outside the broker.

You must call cniFinalize before this call, or it will not work.

Syntax

void cniWriteBuffer(
  int*         returnCode,
  CciMessage*  message);

Parameters

returnCode
The return code from the function (output).
Possible return codes are:
  • CCI_SUCCESS
  • CCI_EXCEPTION
  • CCI_INV_MESSAGE_OBJECT
message
The address of the message object for which the element tree is to be serialized (input).

Return values

None. If an error occurs, the returnCode parameter indicates the reason for the error.

Example

cniCopyElementTree(&rc, inLastChild, outLastChild);
cniFinalize(&rc, outMessage);
cniWriteBuffer(&rc, outMessage);
Related concepts
User-defined output nodes
Notices | Trademarks | Downloads | Library | Support | Feedback

Copyright IBM Corporation 1999, 2007Copyright IBM Corporation 1999, 2007. All Rights Reserved.
This build: July 31, 2007 21:37:23

as07670_ This topic's URL is: