File Utility Program (FUP) Management Programming Manual

FUP Programmatic Interface
File Utility Program (FUP) Management Programming Manual523322-001
2-15
Receiving and Decoding a Response Buffer
To checksum or duplicate the next file in the file set, return the original command buffer
and ZSPI-TKN-CONTEXT to FUP. FUP uses ZSPI-TKN-CONTEXT to determine which
file to process next. After FUP processes the last file in the file set, it returns a reply
without ZSPI-TKN-CONTEXT.
Your application is not required to continue a command when a response record buffer
contains the ZSPI-TKN-CONTEXT token. You can issue other commands before
returning the command with ZSPI-TKN-CONTEXT to FUP, or you can abandon the
continuation of the command altogether.
Processing an Empty Response
If FUP receives a command with the ZSPI-TKN-CONTEXT token and all of the files in
the file set have been processed, FUP returns a response record with ZSPI-TKN-
RETCODE set to ZFUP-ERR-EMPTY-RESP (specifying an empty response). FUP
returns an empty response if the last file in a file set is deleted between the time FUP
returned the previous response record and the time the application sent another
command request with the ZSPI-TKN-CONTEXT token.
Processing Multiple Response Records in a Reply Message
Your application can request multiple response records per reply by setting the SPI
token ZSPI-TKN-MAXRESP. This token specifies the maximum number of response
records your application accepts in a single reply buffer. Multiple response records in a
single reply message can reduce message traffic and improve system performance.
The values for ZSPI-TKN-MAXRESP are:
If you specify a value other than zero for ZSPI-TKN-MAXRESP, FUP returns each
response record in the buffer in a data list. See Figure 2-5.
Figure 2-5. Multiple FUP Response Records
Each data list begins with ZSPI-TKN-DATALIST and ends with ZSPI-TKN-ENDLIST.
Within each data list, the format is the same as the format for a single response record.
0 FUP returns one response record per buffer (not enclosed in a data list). The default is
zero.
-1 FUP returns as many response records per buffer as the buffer can hold (with each
response record enclosed in a data list).
n FUP returns n response records per buffer (with each response record enclosed in a
data list). n must be a positive number.
datalist-1
datalist-2
.
.
.
datalist-n
ZSPI-TKN-CONTEXT (if this is not the last reply message)