ZOSFMSM ;SFISC/AC - SETS UP ^%ZOSF FOR MSM-UNIX SYSTEMS ;8/1/94 11:16
;;8.0;KERNEL;;JUL 03, 1995
S %Y=1 K ^%ZOSF("MASTER"),^%ZOSF("SIGNOFF")
I '$D(^%ZOSF("VOL")) S ^%ZOSF("VOL")=$P($ZU(0),",",2)
K ZO F I="MGR","PROD","VOL" S:$D(^%ZOSF(I)) ZO(I)=^%ZOSF(I)
F I=1:2 S Z=$P($T(Z+I),";;",2) Q:Z="" S X=$P($T(Z+1+I),";;",2,99) S ^%ZOSF(Z)=$S($D(ZO(Z)):ZO(Z),1:X)
MGR W !,"NAME OF MANAGER'S UCI,VOLUME GROUP: "_^%ZOSF("MGR")_"// " R X:$S($G(DTIME):DTIME,1:9999) S:X="" X=^%ZOSF("MGR") X ^("UCICHECK") I 0[Y W *7," ??" G MGR
S ^%ZOSF("MGR")=Y
PROD W !,"PRODUCTION (SIGN-ON) UCI,VOLUME GROUP: "_^%ZOSF("PROD")_"// " R X:$S($G(DTIME):DTIME,1:9999) S:X="" X=^%ZOSF("PROD") X ^("UCICHECK") I 0[Y W *7," ??" G PROD
S ^%ZOSF("PROD")=Y
VOL W !,"NAME OF THIS VOLUME GROUP: "_^%ZOSF("VOL")_"// " R X:$S($G(DTIME):DTIME,1:9999) I X]"" S:X?3U ^%ZOSF("VOL")=X I X'?3U W "MUST BE 3 UPPER case." G VOL
OS S $P(^%ZOSF("OS"),"^")=$S($ZV["MSM":$P($ZV,","),1:"MSM") S:'$P(^%ZOSF("OS"),"^",2) $P(^%ZOSF("OS"),"^",2)=8
W !!,"ALL SET UP",!! Q
;
Z ;;
;;ACTJ
;;S Y=$$ACTJ^%ZOSV()
;;AVJ
;;S Y=$$AVJ^%ZOSV()
;;BRK
;;B 1
;;CPU
;;Q
;;DEL
;;X "ZR ZS @X" K ^UTILITY("%RD",X)
;;EOFF
;;U $I:(::::1)
;;EON
;;U $I:(:::::1)
;;EOT
;;S Y=$ZA\1024#2
;;ERRTN
;;^%ZTER
;;ETRP
;;Q
;;GD
;;D ^%GD
;;LABOFF
;;U IO:(::::1)
;;JOBPARAM
;;G JOBPAR^%ZOSV
;;LOAD
;;S %N=0 X "ZL @X F XCNP=XCNP+1:1 S %N=%N+1,%=$T(+%N) Q:$L(%)=0 S @(DIF_XCNP_"",0)"")=%"
;;LPC;;Parity Check - ASCII sum
;;S Y=$ZCRC(X)
;;MAXSIZ
;;S %K=X D INT^%PARTSIZ
;;MGR
;;MGR,AAA
;;MAGTAPE
;;S %MT("BS")="*1",%MT("FS")="*2",%MT("WTM")="*3",%MT("WB")="*4",%MT("REW")="*5",%MT("RB")="*6",%MT("REL")="*7",%MT("WHL")="*8",%MT("WEL")="*9"
;;MTBOT
;;S Y=$ZA#2
;;MTERR
;;S Y=($ZA\256#8)+($ZA\4096#8)
;;MTONLINE
;;S Y=$ZA\16#4=3
;;MTWPROT
;;S Y=$ZA\2048#2
;;NBRK
;;B 0
;;NO-PASSALL
;;U $I:(:::::8388608)
;;NO-TYPE-AHEAD
;;U $I:(::::100663296)
;;PASSALL
;;U $I:(::::8388608)
;;PRIINQ
;;S Y=$$PRIINQ^%ZOSV()
;;PRIORITY
;;G PRIORITY^%ZOSV
;;PROD
;;VAH,AAA
;;PROGMODE
;;S Y=$$PROGMODE^%ZOSV()
;;RD
;;D ^%RD
;;RESJOB
;;Q:'$D(DUZ) Q:'$D(^XUSEC("XUMGR",+DUZ)) N XQZ S XQZ="^KILLJOB[MGR]" D DO^%XUCI
;;RM
;;U:IOT["TRM" $I:X
;;RSEL
;;K ^UTILITY($J) G ^%RSEL
;;RSUM
;;ZL @X S Y=0 F %=1,3:1 S %1=$T(+%),%3=$F(%1," ") Q:'%3 S %3=$S($E(%1,%3)'=";":$L(%1),$E(%1,%3+1)=";":$L(%1),1:%3-2) F %2=1:1:%3 S Y=$A(%1,%2)*%2+Y
;;SAVE
;;S XCS="F XCM=1:1 S XCN=$O(@(DIE_XCN_"")"")) Q:+XCN'=XCN S %=^(XCN,0) Q:$E(%,1)=""$"" I $E(%,1)'="";"" ZI %" X "ZR X XCS ZS @X" S ^UTILITY("%RD",X)="" K XCS
;;SIZE
;;S Y=0 F I=1:1 S %=$T(+I) Q:%="" S Y=Y+$L(%)+2
;;SS
;;D ^%SS
;;TEST
;;I $D(^ (X))
;;TMK
;;S Y=$ZA\128#2
;;TRAP
;;$ZT=X
;;TRMOFF
;;U $I:(::::::::$C(13,27))
;;TRMON
;;U $I:(::::::::$C(0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127))
;;TRMRD
;;S Y=$ZB
;;TYPE-AHEAD
;;U $I:(::::67108864:33554432)
;;UCI
;;S Y=$ZU(0)
;;UCICHECK
;;S Y=$$UCICHECK^%ZOSV(X)
;;UPPERCASE
;;S Y=$TR(X,"abcdefghijklmnopqrstuvwxyz","ABCDEFGHIJKLMNOPQRSTUVWXYZ")
;;VOL
;;AAA
;;XY
;;U $I:(::::::DY*256+DX)
;;ZD
;;S Y=$ZD(X)
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HZOSFMSM 3254 printed Nov 22, 2024@17:25:31 Page 2
ZOSFMSM ;SFISC/AC - SETS UP ^%ZOSF FOR MSM-UNIX SYSTEMS ;8/1/94 11:16
+1 ;;8.0;KERNEL;;JUL 03, 1995
+2 SET %Y=1
KILL ^%ZOSF("MASTER"),^%ZOSF("SIGNOFF")
+3 IF '$DATA(^%ZOSF("VOL"))
SET ^%ZOSF("VOL")=$PIECE($ZU(0),",",2)
+4 KILL ZO
FOR I="MGR","PROD","VOL"
if $DATA(^%ZOSF(I))
SET ZO(I)=^%ZOSF(I)
+5 FOR I=1:2
SET Z=$PIECE($TEXT(Z+I),";;",2)
if Z=""
QUIT
SET X=$PIECE($TEXT(Z+1+I),";;",2,99)
SET ^%ZOSF(Z)=$SELECT($DATA(ZO(Z)):ZO(Z),1:X)
MGR WRITE !,"NAME OF MANAGER'S UCI,VOLUME GROUP: "_^%ZOSF("MGR")_"// "
READ X:$SELECT($GET(DTIME):DTIME,1:9999)
if X=""
SET X=^%ZOSF("MGR")
XECUTE ^("UCICHECK")
IF 0[Y
WRITE *7," ??"
GOTO MGR
+1 SET ^%ZOSF("MGR")=Y
PROD WRITE !,"PRODUCTION (SIGN-ON) UCI,VOLUME GROUP: "_^%ZOSF("PROD")_"// "
READ X:$SELECT($GET(DTIME):DTIME,1:9999)
if X=""
SET X=^%ZOSF("PROD")
XECUTE ^("UCICHECK")
IF 0[Y
WRITE *7," ??"
GOTO PROD
+1 SET ^%ZOSF("PROD")=Y
VOL WRITE !,"NAME OF THIS VOLUME GROUP: "_^%ZOSF("VOL")_"// "
READ X:$SELECT($GET(DTIME):DTIME,1:9999)
IF X]""
if X?3U
SET ^%ZOSF("VOL")=X
IF X'?3U
WRITE "MUST BE 3 UPPER case."
GOTO VOL
OS SET $PIECE(^%ZOSF("OS"),"^")=$SELECT($ZV["MSM":$PIECE($ZV,","),1:"MSM")
if '$PIECE(^%ZOSF("OS"),"^",2)
SET $PIECE(^%ZOSF("OS"),"^",2)=8
+1 WRITE !!,"ALL SET UP",!!
QUIT
+2 ;
Z ;;
+1 ;;ACTJ
+2 ;;S Y=$$ACTJ^%ZOSV()
+3 ;;AVJ
+4 ;;S Y=$$AVJ^%ZOSV()
+5 ;;BRK
+6 ;;B 1
+7 ;;CPU
+8 ;;Q
+9 ;;DEL
+10 ;;X "ZR ZS @X" K ^UTILITY("%RD",X)
+11 ;;EOFF
+12 ;;U $I:(::::1)
+13 ;;EON
+14 ;;U $I:(:::::1)
+15 ;;EOT
+16 ;;S Y=$ZA\1024#2
+17 ;;ERRTN
+18 ;;^%ZTER
+19 ;;ETRP
+20 ;;Q
+21 ;;GD
+22 ;;D ^%GD
+23 ;;LABOFF
+24 ;;U IO:(::::1)
+25 ;;JOBPARAM
+26 ;;G JOBPAR^%ZOSV
+27 ;;LOAD
+28 ;;S %N=0 X "ZL @X F XCNP=XCNP+1:1 S %N=%N+1,%=$T(+%N) Q:$L(%)=0 S @(DIF_XCNP_"",0)"")=%"
+29 ;;LPC;;Parity Check - ASCII sum
+30 ;;S Y=$ZCRC(X)
+31 ;;MAXSIZ
+32 ;;S %K=X D INT^%PARTSIZ
+33 ;;MGR
+34 ;;MGR,AAA
+35 ;;MAGTAPE
+36 ;;S %MT("BS")="*1",%MT("FS")="*2",%MT("WTM")="*3",%MT("WB")="*4",%MT("REW")="*5",%MT("RB")="*6",%MT("REL")="*7",%MT("WHL")="*8",%MT("WEL")="*9"
+37 ;;MTBOT
+38 ;;S Y=$ZA#2
+39 ;;MTERR
+40 ;;S Y=($ZA\256#8)+($ZA\4096#8)
+41 ;;MTONLINE
+42 ;;S Y=$ZA\16#4=3
+43 ;;MTWPROT
+44 ;;S Y=$ZA\2048#2
+45 ;;NBRK
+46 ;;B 0
+47 ;;NO-PASSALL
+48 ;;U $I:(:::::8388608)
+49 ;;NO-TYPE-AHEAD
+50 ;;U $I:(::::100663296)
+51 ;;PASSALL
+52 ;;U $I:(::::8388608)
+53 ;;PRIINQ
+54 ;;S Y=$$PRIINQ^%ZOSV()
+55 ;;PRIORITY
+56 ;;G PRIORITY^%ZOSV
+57 ;;PROD
+58 ;;VAH,AAA
+59 ;;PROGMODE
+60 ;;S Y=$$PROGMODE^%ZOSV()
+61 ;;RD
+62 ;;D ^%RD
+63 ;;RESJOB
+64 ;;Q:'$D(DUZ) Q:'$D(^XUSEC("XUMGR",+DUZ)) N XQZ S XQZ="^KILLJOB[MGR]" D DO^%XUCI
+65 ;;RM
+66 ;;U:IOT["TRM" $I:X
+67 ;;RSEL
+68 ;;K ^UTILITY($J) G ^%RSEL
+69 ;;RSUM
+70 ;;ZL @X S Y=0 F %=1,3:1 S %1=$T(+%),%3=$F(%1," ") Q:'%3 S %3=$S($E(%1,%3)'=";":$L(%1),$E(%1,%3+1)=";":$L(%1),1:%3-2) F %2=1:1:%3 S Y=$A(%1,%2)*%2+Y
+71 ;;SAVE
+72 ;;S XCS="F XCM=1:1 S XCN=$O(@(DIE_XCN_"")"")) Q:+XCN'=XCN S %=^(XCN,0) Q:$E(%,1)=""$"" I $E(%,1)'="";"" ZI %" X "ZR X XCS ZS @X" S ^UTILITY("%RD",X)="" K XCS
+73 ;;SIZE
+74 ;;S Y=0 F I=1:1 S %=$T(+I) Q:%="" S Y=Y+$L(%)+2
+75 ;;SS
+76 ;;D ^%SS
+77 ;;TEST
+78 ;;I $D(^ (X))
+79 ;;TMK
+80 ;;S Y=$ZA\128#2
+81 ;;TRAP
+82 ;;$ZT=X
+83 ;;TRMOFF
+84 ;;U $I:(::::::::$C(13,27))
+85 ;;TRMON
+86 ;;U $I:(::::::::$C(0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127))
+87 ;;TRMRD
+88 ;;S Y=$ZB
+89 ;;TYPE-AHEAD
+90 ;;U $I:(::::67108864:33554432)
+91 ;;UCI
+92 ;;S Y=$ZU(0)
+93 ;;UCICHECK
+94 ;;S Y=$$UCICHECK^%ZOSV(X)
+95 ;;UPPERCASE
+96 ;;S Y=$TR(X,"abcdefghijklmnopqrstuvwxyz","ABCDEFGHIJKLMNOPQRSTUVWXYZ")
+97 ;;VOL
+98 ;;AAA
+99 ;;XY
+100 ;;U $I:(::::::DY*256+DX)
+101 ;;ZD
+102 ;;S Y=$ZD(X)