Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: INHSYS10

INHSYS10.m

Go to the documentation of this file.
  1. INHSYS10 ;SLT,JPD,WOM; 20 Oct 95 16:03;GIS system configuration compilation/installation utility; program split from INHSYS
  1. ;;3.01;BHL IHS Interfaces with GIS;;JUL 01, 2001
  1. ;COPYRIGHT 1991-2000 SAIC
  1. ;CHCS TOOLS_460; GEN 3; 17-JUL-1997
  1. ;COPYRIGHT 1992 SAIC
  1. Q
  1. LOOP(INUT,INREPRT,INDELETE) ;
  1. ; Input:
  1. ; INUT - Routine to run and Transaction file name
  1. ; INREPRT - 0 - No report
  1. ; 1 - Report
  1. ; INDELETE - If 0/not passed/string then delete
  1. ; IBxxxxW,IBxxxxnn programs
  1. ; else do not delete programs
  1. ;Loop through PASS1 and PASS2
  1. N %PASS,%LFILES,AA,%SAV
  1. K ^UTILITY($J),^UTILITY("INHSYS",$J),^UTILITY("INHSYSUT",$J)
  1. S %DRVR=$P(INUT," -"),INDELETE=+$G(INDELETE)
  1. X "D EN^@%DRVR" ;used eXecute so that ^TCQ program does not crash!
  1. I $D(^UTILITY("INHSYS")),'$$LOCKFL^INHSYSUT(.INLKFLS) D
  1. .F %PASS=1:1:2 D INST^INHSYS05(%DRVR,.%PASS,INREPRT) Q:INPOP
  1. .Q:INPOP D PASS3^INHSYS06
  1. .Q:INPOP D PASS4^INHSYS06
  1. E S INPOP=1
  1. ;Unlock files/Clean up ^UTILITY/Remove IB routines
  1. S AA="" F S AA=$O(INLKFLS(AA)) Q:AA="" D UNLK^INHSYSUT(AA)
  1. K ^UTILITY($J),^UTILITY("INHSYS",$J),^UTILITY("INHSYSUT",$J)
  1. D:'INDELETE RMRTN^INHUT3($E(%DRVR,1,$L(%DRVR)-1))
  1. D ALLSUMER^INHSYS11() ;if error summary is requested, display it on the user's current device
  1. ;
  1. W !!,"File transfer ",$S('INPOP:"completed.",1:"aborted!")
  1. Q
  1. RUN(INREPRT,INSELTT) ;
  1. ; Input:
  1. ; INREPRT - 0 - No report
  1. ; 1 - Report
  1. ; INSELTT -Array of selected files
  1. ;
  1. N INORDR,INROU K ^UTILITY($J),^UTILITY("SVD",$J),^UTILITY("INHSYS",$J)
  1. S INORDR=""
  1. F S INORDR=$O(INSELTT(INORDR)) Q:'INORDR D PARSE(INSELTT(INORDR),.INROU,INREPRT) Q:INPOP
  1. Q:INPOP I $D(INROU) D
  1. .D NTRNL^INHSYS04(.INROU,$E($O(INROU(""),-1),1,6)_"W")
  1. .I INREPRT,$E(IOST)="C",INCR,$$CR^UTSRD(0,IOSL-1)
  1. Q
  1. PARSE(INPTT,INROU,INREPRT) ;begin data collection for a transaction type
  1. ;input:
  1. ; INPTT - ien^.01 parent transaction type from INTERFACE
  1. ; TRANSACTION TYPE file
  1. ; INREPRT - 0 - No report
  1. ; 1 - Report
  1. ;output:
  1. ; INROU - array of compiled routines where INROU(routine)=""
  1. ; Must be passed by referrence as the second parameter
  1. ;
  1. ;set global with file numbers
  1. I INREPRT D HEAD^INHSYS03(1)
  1. ;
  1. ;build storage buffer with transaction type data
  1. D XTRK^INHSYS01(+INPTT,"^INRHT(","^UTILITY($J,4000,",4000,INREPRT,0)
  1. I INPOP K ^UTILITY($J) Q
  1. ;
  1. I INREPRT,$E(IOST)="C",INCR,$$CR^UTSRD(0,IOSL-1)
  1. ;
  1. ;resolve all pointer relationships (ien to .01)
  1. D EXPAND^INHSYS03(INREPRT) Q:INPOP
  1. ;
  1. I INREPRT,$E(IOST)="C",INCR W $$RPTFOOT^INHUT5,@IOF
  1. ;
  1. ;format data into a routine
  1. D RTNBFR^INHSYS04(+INPTT,.INROU)
  1. Q