This interface exit program is used by a message queue monitor that monitors the QSECOFR
message queue for message ID CPI591A (Controller varied off or not recognized by local
system). This exit program is called before and after an option is taken on the monitor
and every time an option is taken. This program only takes action on a pre-processing
call for the option to start the monitor (option 9).
Table 1. Interface exit program example
PGM PARM(&MONITOR &EVTCLS &CMDOPT &PREPOST &RTNCOD &EXCPTID)
/*********************************************************************/
/* Parameters */
/*********************************************************************/
DCL &MONITOR *CHAR 10 /* Monitor name */
DCL &EVTCLS *CHAR 10 /* Event class */
DCL &CMDOPT *CHAR 4 /* Character representation of option */
DCL &PREPOST *CHAR 1 /* Pre or post option call - 0=pre, 1=post */
DCL &RTNCOD *CHAR 1 /* Return code - 0=continue with option */
/* 1=do not continue with */
/* option */
DCL &EXCPTID *CHAR 7 /* Exception ID for history log */
/*********************************************************************/
/* Local variables */
/*********************************************************************/
DCL &STATUS *DEC LEN(5 0)
CHGVAR &RTNCOD VALUE('0')/* '0'=Continue with request */
/*********************************************************************/
/* If this is a pre-processing call for the start option then verify */
/* that the line is ACTIVE. If it isn't then don't start the */
/* monitor. */
/*********************************************************************/
IF ((&PREPOST *EQ '0') *AND (&CMDOPT *EQ '0900')) THEN(DO)
RTVCFGSTS CFGD(TRNLINE) CFGTYPE(*LIN) STSCDE(&STATUS)
IF (&STATUS *EQ 60) THEN(DO)
CHGVAR &RTNCOD VALUE('1')/* Do not start monitor */
CHGVAR &EXCPTID VALUE('MSG0001')
ENDDO
ENDDO
|