*DECK KDISLN
USETEXT NIPDEF
USETEXT ACB
USETEXT AT
USETEXT KDIS
USETEXT KHDRX
USETEXT KSTTAB
USETEXT LLCB
USETEXT NBT
USETEXT PT
PROC KDISLN((RELKN),(ADDRESS),(TYPE)); # DISPLAY K STATUS LINE #
STARTIMS;
#
*1DC KDISLN
*
* 1.PROC NAME AUTHOR DATE
* KDISLN M.GIBIAN 84/01/20
*
* 2.FUNCTIONAL DESCRIPTION.
*
* DISPLAY ONE STATUS K-DISPLAY LINE IN THE STATUS VIEW WINDOW
* BUFFER.
*
* 3.METHOD USED
*
* COMPUTE ABSOLUTE VIEW WINDOW ADDRESS FROM RELATIVE ADDRESS
* IF HEADER LINE, DISPLAY HEADER
* ELSE
* DISPLAY ALL FIELDS FOR TYPE OF DISPLAY LINE
*
* 4.ENTRY PARAMETERS.
*
* RELKN - RELATIVE ADDRESS OF LINE TO BE DISPLAYED
* ADDRESS- ADDRESS OF STRUCTURE CONTAINING DATA TO BE DISPLAYED
* TYPE - TYPE OF STRUCTURE TO DISPLAY (APP, EST, LGL)
*
* 5.OUTPUT PARAMETERS.
*
* 6.COMDECKS AND TEXTS USED.
*
* NIPDEF ACB AT KDIS KHDRX
* KSTTAB LLCB NBT PT
*
* 7.ROUTINES CALLED.
*
* KPUT PUTS VALUES IN BUFFER+CONVERT FROM B TO DISPLAY
* XTRACE RECORD PROCESSOR CALLS
*
* 8.DAYFILE MESSAGES AND OTHER IMPROTANT INFORMATION
* THIS ROUTINE IS CONTAINED IN TWO OVERLAYS. IT MUST
* FIT IN A SPACE SMALLER THAN THE SECONDARY OVERLAY AREA.
*
#
STOPIMS;
#
INPUT PARAMETERS
#
ITEM RELKN; # RELATIVE OFFSET OF LINE #
ITEM TYPE S:KST; # STATUS LINE BUFFER TYPE #
ITEM ADDRESS; # ACB ADDRESS/NBT ENTRY INDEX/LLCB ADDRESS#
#
LOCAL VARIABLES
#
ITEM I I;
ITEM KN I; # ABSOLUTE LINE OFFSET #
ITEM BUF U; # POINTER TO VIEW BUFFER #
ARRAY HEAD[KST"APP":KST"LLK"] S(6);
ITEM HEADER C(0,0,60)=[
" APP JSN STATUS I NCN AC NSM NDM TIME UP",
" EST EQ HN NSM NHM NLM IVTSTAT PRUSTAT FEREJ PV",
" LOG-LINK HN TN N S T NCN AC NHDQ NLDQ TIME UP"];
BASED ARRAY INDEXES S(1);
BEGIN
ITEM ISTART U(0,9,9); # START INDEX IN VIEW TABLE ARRAY #
ITEM IEND U(0,18,9); # END INDEX IN VIEW TABLE ARRAY #
END
SWITCH KLAB:KST
LB$APP:APP,
LB$EST:EST,
LB$LLK:LLK;
#
EXTERNAL CALLS
#
XREF
BEGIN
PROC KPUT;
PROC XTRACE;
END
#
CHECK TO SEE IF HEADER NEEDS TO BE DISPLAYED
#
BEGIN
CONTROL IFEQ DEBUG,1;
XTRACE("KDISL");
CONTROL FI;
BUF = KHDRNP[0];
P<KSTTAB> = BUF + BLKHSIZE + KHDRSIZE;
P<INDEXES>=LOC(KDAPPST[0])-1;
FOR I=KST"APP" STEP 1 WHILE ISTART[I] EQ 0 DO;
KN=RELKN-ISTART[I];
FOR I=KST"APP" STEP 1 UNTIL TYPE-1 DO KN=KN+IEND[I];
IF RELKN EQ 2 THEN
BEGIN
KAPPDTA[KN]=HEADER[TYPE];
GOTO LB$;
END
GOTO KLAB[TYPE]; # SWITCH ON DISPLAY TYPE #
LB$APP: # PROCESS DISPLAY OF APPLICATION ON THE LINE #
#
NOW GO GENERATE THE DISPLAY LINE FOR THE
APPLICATIONS SHOWN IN THE VIEW BUFFER
#
P<ACB>=ADDRESS;
KAPPNM [KN] = ACBANAME[0];
KAPPJSN[KN] = ACBJOBSQN[0] ;
KAPPI[KN] = " " ; # IF NOT ALLOWED FOR K-DISPLAY #
IF ATK[ACBAN[0]]
THEN
BEGIN
KAPPI[KN] = "N" ; # IF NOT IN IGNORE-ALERT STATE #
IF ATI[ACBAN[0]]
THEN
KAPPI[KN] = "Y" ;
END
KAPPTUP[KN] = ACBTIMC[0] ;
KPUT(BUF,KN,KPAPNCN,ACBNCN[0]);
KPUT(BUF,KN,KPAPAC ,ACBLMTC[0]);
KPUT(BUF,KN,KPAPNSM,ACBSMQ[0]);
KPUT(BUF,KN,KPAPNDM,ACBBLKSQ[0]);
KPUT(BUF,KN,KPAPSTWD,ATASBV[ACBAN[0]]);
# END OF AT SEARCH #
GOTO LB$;
LB$EST: # DISPLAY EST ON THE DISPLAY LINE #
#
AND UPDATE AS MANY FIELDS AS YOU CAN
#
KPUT(BUF,KN,KPESNO,NBTEST[ADDRESS+0]);
KPUT(BUF,KN,KPESET,NBTET[ADDRESS+0]);
KPUT(BUF,KN,KPESHN,NBTHN[ADDRESS+0]);
NBTIVTLS[ADDRESS+2]=NBTIVTCC[ADDRESS+2] ;
NBTPRULS[ADDRESS+3]=NBTPRUCC[ADDRESS+3] ;
KPUT(BUF,KN,KPESREJ,NBTNIREJ[ADDRESS+4]);
KPUT(BUF,KN,KPESPV,NBTPV[ADDRESS+5]);
#
END NBTE SEARCH
#
GOTO LB$;
LB$LLK: # DISPLAY LGL ENTRY ON THIS LINE #
#
AND UPDATE AS MANY FIELDS AS YOU CAN
#
P<LLCB>=ADDRESS;
KPUT(BUF,KN,KPLGHN,LLCBHN[0]);
KPUT(BUF,KN,KPLGTN,LLCBTN[0]);
KLGLTUP[KN] = LLCBTMC[0] ;
KPUT(BUF,KN,KPLGN ,LLCBNRL[0]);
KLGLS[KN] = " "; # IN CASE CS NOT USING THIS LINK #
IF LLCBCS[0]
THEN
KLGLS[KN] = "S" ;
KLGLT[KN] = " ";
IF LLCBHH[0] # THIS IS AN A-A CONNECTION #
THEN
KLGLT[KN] = "H" ;
KPUT(BUF,KN,KPLGNCN,LLCBNC[0]);
KPUT(BUF,KN,KPLGAC ,LLCBLMTC[0]);
GOTO LB$;
LB$:
KAPPEND[KN]=0;
RETURN;
END
TERM