IEWBUFF - Binder API buffers interface assembler macro for generating and mapping data areas

This topic is specifically for users of the IEWBIND and IEWBUFF macros. It includes a complete description of the use of IEWBUFF, as well as supplemental material on the IEWBIND macro. If you are calling the binder API from languages other than assembler or IBM's internal PL/X, you must follow the instructions presented in Invoking the binder without the macros together with the IEWBIND interface parameter details given in IEWBIND function reference.

The binder uses a standardized buffer structure to pass data to and from calling programs. Each buffer begins with a header containing the following information:
  1. A doubleword containing an identifier
  2. A fullword containing the length of the buffer (including the header)
  3. A one-byte version identifier followed by three bytes of zeroes
  4. A fullword containing the length of each entry in the buffer ('1' if the buffer holds TEXT data)
  5. A fullword containing the number of bytes (for TEXT data) or records (for other data types) the buffer can hold.

This section describes how to use the IEWBUFF macro to generate and initialize buffers and to obtain and release the necessary storage. The record layouts for each buffer type are illustrated in Binder API buffer formats.