Previous Topic: What You Can DoNext Topic: Coding a COBOL Input Module


How Information Is Passed

Information is passed between CA Culprit and an input module by means of an argument list, which is set up by CA Culprit from system and user-supplied information. The following considerations apply:

The input module arguments, their function, and address pointers are listed in the following table.

Input Module Argument List and Address Pointers

Addresses are passed by the CULL step through Register 1 to all input modules called in a CA Culprit run.

Argument name

Function/comments

Displacement from Register 1

INPUT

The address of the CA Culprit input buffer accessed within the input module code.

0

DEVINDS

The address of type and DTF codes used internally by CA Culprit.

4

OPNCLS

The address of a 1-byte user-supplied open/close switch accessed within the input module code. The following table lists allowable switch values.

8

FILSPEC

The address for record and label-type codes for the input file being read.

12

RECSIZE

The address for the record size (halfword) of the input file records.

16

BLKSIZE

The address for the blocksize (halfword) of the input file.

20

FILDESC

The address for the external file name (8-bytes alphanumeric) and logical unit (1-byte hexadecimal) for the input file.

24

ISKEY

The address of an internal CA Culprit key field not accessible by the user.

28

VPRINT

The entry address for the CA Culprit print routine used to print user-defined diagnostic and error message relating to the input buffer.

VPRINT cannot be called by a COBOL user module. For Assembler modules, call the VCON print routine address and pass the address of the line of data to be printed.

32

ASELTBL

The address of the internal select table used by input module select routines (CULLCBSL, CULSLCT, and CULSINIT).

36

VSEL

The VCON address for the CULLSEL module used by input module select routines.

40

VDBEXIT

The address for the DBEXIT module supplied by the input module for the CULL step. VDBEXIT is not accessible by the user.

44

COMMONA

A common area for internal CA Culprit use. COMMONA is not accessible by the user.

48

ALTDESC

The address if the filename/ddname and logical unit for an alternate file specified with the INPUT parameter DD2 option.

52

PASSWD

The address of an 8-byte user-specified password, as specified on the INPUT parameter.

56

Input Module Open/close Switch Values

If the open/close switch is not set to one of these values, CA Culprit outputs an error message stating the contents of the switch.

Hexadecimal value

File status

Binary value

X'FF'

The input file is closed and must be opened by resetting the value to X'00'.

255

X'00'

The input file is open and can read and deliver records to the CA Culprit input buffer until an end-of-file condition is encountered. Close the file and reset this value to X'FF' when end-of-file is reached.

0

X'0F'

The STOP action has been encountered in procedure code. The input module closes the input file. Reset this value to X'FF'.

15

X'F0'

The input module code can use this value to indicate an I/O error. If used and an I/O error is found, reset this value to X'FF'.

240