IBM Integration Bus, Version 10.0.0.1 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS


cpiCreateContext

This function creates a user-defined extension context associated with a parser object. It is called by the integration node when an instance of a parser object is constructed or allocated. This action occurs when a message flow causes the message data to be parsed; the integration node constructs or allocates a parser object to acquire the appropriate section of the message data.

Before this function is called, the integration node creates a name element as the effective root element for the parser. However, this element is not named. The parser must name this element in the cpiSetElementName function.

The responsibilities of the extension are to:
  1. Allocate all parser-instance specific data areas (such as context) that might be required.
  2. Perform all additional resource acquisition or initialization that might be required.
  3. Return the address of the context to the calling function. Whenever an implementation function for this parser instance is called, the appropriate context is passed as an argument to that function. Therefore, a user-defined parser developed in C need not maintain its own static pointers to per-instance data areas.
Defined In Type Member
CPI_VFT Mandatory iFpCreateContext

Syntax

void cpiCreateContext(
  CciParser*   parser);

Parameters

parser
The address of the parser object (input).

Return values

If successful, the address of the user-defined extension context is returned. Otherwise, a value of zero is returned.


as08095_.htm | Last updated 2015-05-28 20:51:46