Appendix F. Batch Application Program Interface (API) 643
1st ed., 6/30/04 - 312579601
*
* CONDITIONALLY BRANCH TO CLOSE LABEL WHEN AN APPROPRIATE
* LOOP TERMINATION CONDITION HAS BEEN SATISFIED (NOT SHOWN).
*
B PROCESS REPEAT MAIN PROCESSING LOOP
*
* CLOSE THE ACS AND DRIVE RECORD AREAS:
*
CLOSE DS 0H CLOSE ACS AND DRIVE RECORD AREAS:
SLSUREQ QCDS, CLOSE THE ACS RECORD AREA
REQUEST=CLOSE,
TYPE=ACS,
TOKEN=WKTOK,
UCALADR=WKUCAL,
MF=(E,WKQCDS)
SLSUREQ QCDS, CLOSE THE DRIVE RECORD AREA
REQUEST=CLOSE,
TYPE=DRV,
TOKEN=WKTOK,
UCALADR=WKUCAL,
MF=(E,WKQCDS)
*
* CLEAN UP AND RETURN TO CALLER:
*
EXIT DS 0H CLEAN UP AND RETURN TO CALLER:
DELETE EP=SLSUCAL UNLOAD SLSUCAL ROUTINE
LR R1,R13 POINTER TO MODULE WORK AREA
L R13,4(,R13) RESTORE CALLER’S SAVE AREA
FREEMAIN R,A=(R1),LV=WKAREAL RELEASE MODULE WORK AREA
L R14,12(,R13) RESTORE RETURN ADDRESS
LM R0,R12,20(R13) RESTORE CALLER’S REGISTERS 0!12
XR R15,R15 SET ZERO RETURN CODE
BR R14 RETURN TO CALLER
*
* CONSTANTS:
*
QCDSMODL SLSUREQ MF=L SLSUREQ PLIST MODEL
QCDSMLEN EQU *!QCDSMODL LENGTH OF SLSUREQ PLIST MODEL
QCDSDD DC CL8’MVS1CDS ‘ 8!CHAR BLANK!PADDED CDS DDNAME
QCDSBLEN DC F’1024’ QCDS READ RESPONSE AREA BUFFER LENGTH
*
* MODULE WORK AREA MAP:
*
WKAREA DSECT MODULE WORK AREA
WKSAVE DS 18F MVS REGISTER SAVE AREA
WKUCAL DS A SLSUCAL ROUTINE ADDRESS
WKTOK DS F QCDS REQUEST TOKEN
WKQCDS DS XL(QCDSMLEN) SLSUREQ PLIST STORAGE
WKACSBUF DS XL1024 ACS RESPONSE AREA BUFFER
WKDRVBUF DS XL1024 DRV RESPONSE AREA BUFFER
WKAREAL EQU *!WKAREA LENGTH OF MODULE WORK AREA
Figure 34. Sample 2- Reading ACS and DRV Together
(3 of 4)