IVMUTQ ;ALB/ESD - Device Handling and Queueing Utility ; 03-FEB-93
;;Version 2.0 ; INCOME VERIFICATION MATCH ;; 21-OCT-94
;;Per VHA Directive 10-93-142, this routine should not be modified.
;
; This routine is a generic interface to the device handler (^%ZIS)
; and task manager (^%ZTLOAD). It will handle device opening and
; closing and variable clean-up.
;
; Input (to be defined by the caller of the routine):
;
; IVMRTN - application routine entry point for output (required).
; %ZIS - device call variable (set to "QMP" if not defined).
; ZTDESC - description of task (set if not defined).
; ZTSAVE - input parameters to be saved (set to IVMRTN).
;
; NOTE: Other optional input variables for %ZIS and %ZTLOAD calls
; may be defined as described in KERNEL documentation.
;
;
EN I $G(IVMRTN)="" W !!,"Routine aborted...entry point not defined." G ENQ
I $D(%ZIS)#2=0 S %ZIS="QMP"
D ^%ZIS K %ZIS G:POP ENQ
I '$D(IO("Q")) U IO D @IVMRTN,^%ZISC,ENQ Q
;
; task job
S ZTRTN=@"IVMRTN",ZTSAVE("IVMRTN")=""
I '$D(ZTDESC) S ZTDESC="IVM UNKNOWN OPTION"
D ^%ZTLOAD
W !,$S($D(ZTSK):"Job has been queued. The task number is "_ZTSK_".",1:"Unable to queue this job.")
D HOME^%ZIS
;
ENQ ; clean-up
K IO("Q"),IVMRTN,POP,ZTCPU,ZTDESC,ZTDTH,ZTIO,ZTKIL,ZTPRI,ZTRTN,ZTSAVE,ZTUCI,ZTSK
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HIVMUTQ 1367 printed Dec 13, 2024@02:03:06 Page 2
IVMUTQ ;ALB/ESD - Device Handling and Queueing Utility ; 03-FEB-93
+1 ;;Version 2.0 ; INCOME VERIFICATION MATCH ;; 21-OCT-94
+2 ;;Per VHA Directive 10-93-142, this routine should not be modified.
+3 ;
+4 ; This routine is a generic interface to the device handler (^%ZIS)
+5 ; and task manager (^%ZTLOAD). It will handle device opening and
+6 ; closing and variable clean-up.
+7 ;
+8 ; Input (to be defined by the caller of the routine):
+9 ;
+10 ; IVMRTN - application routine entry point for output (required).
+11 ; %ZIS - device call variable (set to "QMP" if not defined).
+12 ; ZTDESC - description of task (set if not defined).
+13 ; ZTSAVE - input parameters to be saved (set to IVMRTN).
+14 ;
+15 ; NOTE: Other optional input variables for %ZIS and %ZTLOAD calls
+16 ; may be defined as described in KERNEL documentation.
+17 ;
+18 ;
EN IF $GET(IVMRTN)=""
WRITE !!,"Routine aborted...entry point not defined."
GOTO ENQ
+1 IF $DATA(%ZIS)#2=0
SET %ZIS="QMP"
+2 DO ^%ZIS
KILL %ZIS
if POP
GOTO ENQ
+3 IF '$DATA(IO("Q"))
USE IO
DO @IVMRTN
DO ^%ZISC
DO ENQ
QUIT
+4 ;
+5 ; task job
+6 SET ZTRTN=@"IVMRTN"
SET ZTSAVE("IVMRTN")=""
+7 IF '$DATA(ZTDESC)
SET ZTDESC="IVM UNKNOWN OPTION"
+8 DO ^%ZTLOAD
+9 WRITE !,$SELECT($DATA(ZTSK):"Job has been queued. The task number is "_ZTSK_".",1:"Unable to queue this job.")
+10 DO HOME^%ZIS
+11 ;
ENQ ; clean-up
+1 KILL IO("Q"),IVMRTN,POP,ZTCPU,ZTDESC,ZTDTH,ZTIO,ZTKIL,ZTPRI,ZTRTN,ZTSAVE,ZTUCI,ZTSK
+2 QUIT