

7. PARAMETERS › 7.3 Unit Level Parameters › 7.3.5 Print Output Definition (PRINTDEF)
7.3.5 Print Output Definition (PRINTDEF)
The PRINTDEF member contains a user exit that processes
information on the total number of lines printed from the
spool for a job.
The exit determines which type of output device was used and
increases the value of the printer-related data elements
(JOBNLRx) by the number of logical lines printed by the job,
as represented by data element JOBNLR (Logical Writer
Records). JOBNLR is the total of the values contained in the
SPLNLR data element for each output file in the job.
Using a set of switches, the routine determines whether a
local or a remote printer is used and which device type was
used to produce the job output. It then adds the number of
print lines to one of the following variables:
JOBNLRP - Punched Card Logical Writer Records
JOBNLRI - Line (Impact) Printer Logical Writer Records
JOBNLRL - Laser Printer Logical Writer Records
JOBNLRC - Microfiche Com Printer Logical Writer Records
JOBNLRR - Remote Printer Logical Writer Records
JOBNLRU - User-defined Logical Writer Records
PRINTDEF should be coded to perform two tasks. The first is
to set the value of the ROUTE data element. The ROUTE data
element contains the routing destination for JES2 remote
output. On entry to the PRINTDEF routine, the ROUTE element
will be set to the following values:
ROUTE = 0-NNN (JES2, WHERE 0 IS LOCAL AND N REMOTE)
ROUTE = 0 (JES3)
o For JES2, ROUTE will be 0 for local print. For remote
print, it will have the value of the remote number.
o For JES3, ROUTE will be 0, and the user must provide
code to assign a non-zero value to ROUTE for remote
print.
o If the value of ROUTE is non-zero, the count contained
in JOBNLRR (Remote Printer Logical Writer Records)
will be incremented.
o For special local routing, ROUTE will be 0 and
SPLOCRTE will equal the route code.
The second task is to set the switch variable to 1 for the
corresponding output device if the print is local. This can
be done using variables such as SYSOUT and DEVNAME. The
switch variables are:
XNLRP - card punch
XNLRI - impact printer
XNLRL - laser printer
XNLRC - microfiche com printer
XNLRU - user-defined device
On entry to the PRINTDEF routine, the switch and data
variables will be set as follows:
SYSOUT = OUTPUT CLASS USED
XNLRI = 0 IMPACT LINE PRINTER NOT USED
XNLRL = 0 3800 LASER PRINTER NOT USED
XNLRC = 0 MICROFICHE COM PRINTER NOT USED
XNLRP = 0 CARD PUNCH NOT USED
XNLRU = 0 USER-DEFINED PRINTER NOT USED
DEVNAME = OUTPUT DEVICE TYPE (E.G., PRINTER1)
The routine in PRINTDEF is used to determine to which of
these data elements the number of lines should be added.
EXAMPLE
For example, an installation that uses a 3800 laser printer
as the major spool output medium and directs the use of other
spool output types by SYSOUT class (where class C is for the
impact printer, B is for punched cards, and R is for
microfiche COM output) might use the following:
IF SYSOUT='C' THEN XNLRI=1;
ELSE IF SYSOUT='B' THEN XNLRP=1;
ELSE IF SYSOUT='R' THEN XNLRC=1;
ELSE XNLRL=1;
The values set for the switch variables and ROUTE in the
PRINTDEF routine are used in the routine as follows:
IF XNLRP=1 THEN JOBNLRP+SPLNLR;
ELSE IF XNLRI=1 THEN JOBNLRI+SPLNLR;
ELSE IF XNLRL=1 THEN JOBNLRL+SPLNLR;
ELSE IF XNLRC=1 THEN JOBNLRC+SPLNLR;
ELSE IF ROUTE>0 THEN JOBNLRR+SPLNLR;
ELSE IF XNLRU=1 THEN JOBNLRU+SPLNLR;
IF XNLRL=1 THEN JOBPNLRL+SPLPNLR;
Note that this code only adds the number of logical lines to
one of the JOBNLRx variables. The local output types are
tested first, then the test for remote print is done, and
finally the test for a user-defined output type is performed.
This order allows you to use the JOBNLRU (User-defined
Logical Writer Records) data element as a catch-all for
output types you do not wish to break down further. Note
also that the accumulation of the total number of lines
printed and punched by the job (JOBNLR) is not affected by
the assignments made in PRINTDEF.
For the sample code above, if a job punched 250 cards and
printed 8000 lines on a laser printer, the variables in the
BATJOB File would be set as follows:
JOBNLR = 8250
JOBNLRP = 250
JOBNLRI = 0
JOBNLRL = 8000
JOBNLRC = 0
JOBNLRR = 0
JOBNLRU = 0
Copyright © 2014 CA.
All rights reserved.
 
|
|