2.7 Using a VIEW Typed Buffer
There are two kinds of VIEW typed buffers. The
first, FML VIEW, is a C structure generated from an
FML buffer. The second is simply an independent C
structure.
The reason for converting FML buffers into C structures and back again (and the purpose of the FML VIEW typed buffers) is that while FML buffers provide data-independence and convenience, they incur processing overhead because they must be manipulated using FML function calls. C structures, while not providing flexibility, offer the performance required for lengthy manipulations of buffer data. If you need to perform a significant amount of data manipulation, you can improve performance by transferring fielded buffer data to C structures, operating on the data using normal C functions, and then converting the data back to the FML buffer for storage or message transmission.
For more information on the FML typed buffer and
FML file conversion, refer to the Oracle Tuxedo
ATMI FML Function Reference.
To use VIEW typed buffers, you must perform the
following steps:
- Set the appropriate environment variables.
- Describe each structure in view description files.
- Compile the view description files using
viewc, the Oracle Tuxedo view compiler. Specify the resulting header file in the#includestatement for your application program.