User Tools

Site Tools


cdc:nos2.source:nam5871:ndlnfnt

NDLNFNT

Table Of Contents

  • [00008] PROC NDLNFNT
  • [00012] NCF NETWORK ELEMENTS
  • [00061] PROC ABORT
  • [00062] PROC SSTATS
  • [00063] PROC MESSAGE
  • [00064] PROC READW
  • [00065] PROC NDLTRNK
  • [00066] PROC NDLWNCF
  • [00121] PROC CHKNODE(NODE$VAL,MXNO,UNQFLG,INRANGE)
  • [00126] CHKNODE - CHECK NODE VALUE
  • [00166] PROC NDLEM2
  • [00167] FUNC XCDD C(10)
  • [00204] PROC CPLERPR
  • [00208] CPLERPR - COUPLER PROCESSOR
  • [00245] PROC NDLEM2
  • [00364] PROC LLINKPR
  • [00368] LLINKPR - LOGICAL LINK PROCESSOR
  • [00416] PROC NDLEM2
  • [00581] PROC NFILEPR
  • [00586] NFILEPR - NFILE STATEMENT PROCESSOR
  • [00615] FUNC EDATE C(10)
  • [00616] FUNC ETIME C(10)
  • [00617] PROC PDATE
  • [00618] PROC RECALL
  • [00619] PROC REWIND
  • [00620] PROC VERSION
  • [00621] PROC NDLZFIL
  • [00706] PROC NPUPR
  • [00711] NPUPR - NPU PROCESSOR
  • [00753] PROC NDLEM2
  • [00903] PROC RNGNODE(NODEVAL,MAX,RNGFLG)
  • [00908] PRGNODE - CK RANGE OF NODE
  • [00943] PROC NDLEM2
  • [00944] FUNC XCDD C(10)
  • [00965] PROC SLINKPR
  • [00969] SLINKPR - SUPLINK PROCESSOR
  • [01005] PROC NDLEM2
  • [01060] PROC SLINKXR(LLENT)
  • [01064] SLINKXR - SUPLINK CROSS REFERINCE

Source Code

NDLNFNT.txt
  1. *DECK NDLNFNT
  2. USETEXT NDLDATT
  3. USETEXT NDLER2T
  4. USETEXT NDLFETT
  5. USETEXT NDLNCFT
  6. USETEXT NDLPS2T
  7. USETEXT NDLTBLT
  8. PROC NDLNFNT;
  9. BEGIN
  10. *IF,DEF,IMS
  11. #
  12. ** NDLNFNT - NCF NETWORK ELEMENTS
  13. *
  14. * S.M. ILMBERGER 81/11/2
  15. *
  16. * PROCESS NETWORK ELEMENT STATEMENTS
  17. *
  18. * PROC NDLNFNT
  19. *
  20. * ENTRY NONE
  21. *
  22. * EXIT NONE
  23. *
  24. * MESSAGES
  25. * INVALID STMT I.D.-ABORT FROM NCFNET
  26. *
  27. * METHOD
  28. *
  29. * FOR EACH "NETWORK" OR "TRUNK" TYPE STATEMENT IN STMT$TABLE
  30. * READ FULL STATEMENT
  31. * IF STATEMENT IS NFILE
  32. * CLEAR PRFX$TABLE AND VERIFY$ENTRY
  33. * CALL NFILE STATEMENT PROCESSOR
  34. * IF STATEMENT IS NPU
  35. * GET AND CLEAR NEXT ENTRY OF NPU$XREF TABLE
  36. * CALL NPU STATEMENT PROCESSOR
  37. * IF STATEMENT IS SUPLINK
  38. * GET AND CLEAR NEXT ENTRY OF SUPLINK TABLE
  39. * CALL SUPLINNK STATEMENT PROCESSOR
  40. * IF STATEMENT IS COUPLER
  41. * GET AND CLEAR NEXT ENTRY OF PLINK$XREF TABLE
  42. * CALL COUPLER STATEMENT PROCESSOR
  43. * IF STATEMENT IS LOGLINK
  44. * GET AND CLEAR NEXT ENTRY OF LOGLINK$XREF
  45. * CALL LOGLINK STATEMENT PROCESSOR
  46. * IF STATEMENT IS TRUNK
  47. * GET AND CLEAR NEXT ENTRY OF PLINK$XREF TABLE
  48. * CALL TRUNK STATEMENT PROCESSOR
  49. * IF STATEMENT HAS NOT MATCHED A STATEMENT ID
  50. * SEND ERROR MESSAGE
  51. * READ NEXT STATEMENT HEADER
  52. * END
  53. *
  54. #
  55. *ENDIF
  56. #
  57. **** PROC NDLNFNT - XREF LIST BEGINS
  58. #
  59. XREF
  60. BEGIN
  61. PROC ABORT; # ABORTS NDLP #
  62. PROC SSTATS; # ALLOCATE MORE TABLE SPACE #
  63. PROC MESSAGE; # MAKE DAYFILE AND SYSTEM CONSOLE MESSAGE #
  64. PROC READW; # READ STATEMENT TABLE #
  65. PROC NDLTRNK; # PROCESS TRUNK STATEMENT #
  66. PROC NDLWNCF; # WRITE RECORD TO NCF-FILE #
  67. END
  68. #
  69. ****
  70. #
  71.  
  72. DEF FSTCT # 1 #; # FIRST ENTRY IN COUPLER TABLE #
  73. DEF FSTLL # 1 #; # FIRST ENTRY IN LOGLINK-XREF-TABLE #
  74. DEF FSTLLT # 1 #; # FIRST ENTRY IN LOGLINK TABLE #
  75. DEF FSTNT # 1 #; # FIRST ENTRY IN NPU TABLE #
  76. DEF FSTPL # 1 #; # FIRST ENTRY IN PHYSICAL-LINK-XREF TAB #
  77. DEF LEN$FH$TAB # 17 #; # LENGTH OF TABLE TO WRITE TO NCF #
  78. DEF SECLL # 2 #; # SECOND ENTRY IN LOGLINK-XREF TAB #
  79.  
  80. ITEM COMM$RD$ER B; # INDICATES STMT IS COMMUNICATION TYPE OR #
  81. # A READ ERROR OCCURED #
  82. ITEM CPL$CNT I; # NUMBER OF COUPLERS ON CURRENT NPU #
  83. ITEM CRNT$CPL C(7); # NAME OF CURRENT COUPLER #
  84. ITEM CRNT$CNID; # NODE I.D. OF CRUENT COUPLER #
  85. ITEM CRNT$HNAM C(7); # NAME OF CURRENT HNAME #
  86. ITEM FWAWSA; # 1ST WORD ADDRESS OF WORKING STORAGE AREA#
  87. ITEM I; # LOOP COUNTER #
  88. ITEM PRI$USED B; # PRIMARY SPECIFIED FLAG #
  89. ITEM SEC$USED B; # SECONDARY SPECIFIED FLAG #
  90.  
  91. ARRAY STMT$TAB [0:11] S(1); # ROUTES STMT TO NETWORK OR #
  92. BEGIN # COMMUNICATION PROCESSOR #
  93. ITEM STMT$TYPE C(0,0,10) = [,"NETWORK ", # NFILE #
  94. "NETWORK ", # NPU #
  95. "NETWORK ", # SUPLINK #
  96. "NETWORK ", # COUPLER #
  97. "NETWORK ", # LOGLINK #
  98. "COMMUNIC ", # GROUP #
  99. "COMMUNIC ", # LINE #
  100. "COMMUNIC ", # REPEAT #
  101. "COMMUNIC ", # TERMINAL #
  102. "COMMUNIC ", # DEVICE #
  103. "TRUNK " # TRUNK #
  104. ];
  105. END
  106.  
  107. SWITCH NET$ELEM ERR$NET , # UNK #
  108. NFILE$ST, # NFILE #
  109. NPU$ST , # NPU #
  110. SLINK$ST, # SUPLINK #
  111. COUP$ST , # COUPLER #
  112. LLINK$ST, # LOGLINK #
  113. ERR$NET ,
  114. ERR$NET ,
  115. ERR$NET ,
  116. ERR$NET ,
  117. ERR$NET ,
  118. TRNK$ST ; # TRUNK #
  119.  
  120. CONTROL EJECT;
  121. PROC CHKNODE(NODE$VAL,MXNO,UNQFLG,INRANGE);
  122. # CHECKS THAT NODE NUMBER IS UNIQUE #
  123. BEGIN # CHKNODE PROC #
  124. *IF,DEF,IMS
  125. #
  126. ** CHKNODE - CHECK NODE VALUE
  127. *
  128. * S.M. ILMBERGER 81/10/30
  129. *
  130. * CHECK UNIQUENESS OF NODE NUMBER
  131. *
  132. * PROC CHKNODE(NODE$VAL,MXNO,UNQFLG,INRANGE)
  133. *
  134. * ENTRY NODE$VAL - NODE NUM TO CHECK UNIQUENESS OF
  135. * MXNO - MAXIMUM VALUE NODE CAN HAVE
  136. *
  137. * EXIT UNQFLG - FLAG INDICATING IF NODE IS UNIQUE
  138. * INRANGE - FLAG INDICATING IF NODE IS IN RANGE
  139. *
  140. * MESSAGES NONE
  141. *
  142. * METHOD
  143. *
  144. * CALL RNGNODE TO CK IF NODE IS IN RANGE
  145. * IF NODE IS INRANGE
  146. * CK BITMAP FOR UNIQUENESS
  147. * IF NOT UNIQUE
  148. * SEND ERROR MSG
  149. * ELSE
  150. * SET BIT IN BITMAP
  151. * END
  152. *
  153. #
  154. *ENDIF
  155.  
  156. ITEM CNODEVAL C(10); # CHARACTER STORAGE FOR NODE NUMBER #
  157. ITEM NODE$VAL I; # NODE NUMBER TO CHECK UNIQUENESS ON #
  158. ITEM MXNO I; # MAX NUMBER NODE CAN HAVE #
  159. ITEM UNQFLG B; # NODE UNIQUENESS FLAG #
  160. # TRUE IF VALUE IS UNIQUE #
  161. ITEM INRANGE B; # RANGE RESTRAINT FLAG #
  162. # TRUE WHEN NODE NUMBER IS IN RANGE #
  163.  
  164. XREF
  165. BEGIN
  166. PROC NDLEM2; # MAKES ENTRY IN ERROR-FILE-2 #
  167. FUNC XCDD C(10); # CONVERTS INTEGER TO DECIMAL DISPLAY CODE#
  168. END
  169.  
  170. ITEM BIT; # INDICATES BIT NUMBER OF BITMAP #
  171. ITEM WORD; # INDICATES WORD OF BITMAP #
  172.  
  173. CONTROL EJECT;
  174. # #
  175. # CODE BEGINS HERE #
  176. # #
  177.  
  178. BIT = 0;
  179. WORD = 0;
  180. UNQFLG = TRUE; # NODE IS UNIQUE #
  181. RNGNODE(NODE$VAL,MXNO,INRANGE); # CK IF NODE IS RANGE #
  182. IF INRANGE
  183. THEN
  184. BEGIN
  185. WORD = (NODE$VAL-1) / 60; # COMPUTE CORRECT WORD OF BITMAP #
  186. BIT = (NODE$VAL-1) - (60 * WORD); # AND BIT TO REFER TO #
  187. IF B<BIT,1>BITMAP[WORD] EQ 1 # TEST BIT IN BITMAP #
  188. THEN # IF ALREADY SET #
  189. BEGIN
  190. CNODEVAL = XCDD(NODE$VAL); # CONVERT INTEGER TO DEC DISPLAY#
  191. NDLEM2(ERR125,STLNUM[0],CNODEVAL); # SEND ERROR MSG #
  192. UNQFLG = FALSE; # SET FLAG TO INDICATE VALUE NOT UNIQUE #
  193. END
  194. ELSE # OTHERWISE SET FLAG #
  195. BEGIN
  196. B<BIT,1>BITMAP[WORD] = 1;
  197. END
  198. END # IF INRANGE #
  199. RETURN;
  200.  
  201. END # CHKNODE PROC #
  202.  
  203. CONTROL EJECT;
  204. PROC CPLERPR; # PROCESS COUPLER STATEMENT #
  205. BEGIN
  206. *IF,DEF,IMS
  207. #
  208. ** CPLERPR - COUPLER PROCESSOR
  209. *
  210. * S.M. ILMBERGER 81/10/30
  211. *
  212. * PROCESS COUPLER STATEMENT
  213. *
  214. * PROC CPLERPR
  215. *
  216. * ENTRY NONE
  217. *
  218. * EXIT NONE
  219. *
  220. * MESSAGES
  221. * INVALID KEYWORD I.D.-ABORT FROM CPLERPR
  222. *
  223. * METHOD
  224. *
  225. * IF NO LABEL ERROR
  226. * SAVE COUPLER NAME
  227. * SET COUPLER FLAG IN PLINK$XREF
  228. * FOR EACH KEYWORD ON STATEMENT
  229. * IF NO VALUE ERROR
  230. * SAVE INFO IN APPROPRIATE POSITION OF PLINK$XREF TABLE
  231. * IF NO NODE OR HNAME PARAMETER SPECIFIED
  232. * FLAG ERROR
  233. * IF DUPLICATE COUPLER LOC VALUE
  234. * FLAG ERROR
  235. * IF MORE THAN TWO COUPLERS
  236. * FLAG ERROR
  237. * SET BIT IN LOC BITMAP FOR LOC VALUE
  238. * END
  239. *
  240. #
  241. *ENDIF
  242.  
  243. XREF
  244. BEGIN
  245. PROC NDLEM2; # MAKE ENTRY IN ERROR-FILE-2 #
  246. END
  247.  
  248. DEF COUP$PAR # "COUPLER" #; # FOR ERROR MESSAGE #
  249. DEF HNAME$PAR # "HNAME" #; # FOR ERROR MESSAGE #
  250. DEF MX$NODE # 255 #; # MAX NODE NUMBER ON COUPLER STATEMENT #
  251. DEF NODE$PAR # "NODE" #; #FOR ERROR MESSAGE #
  252. DEF PRI1 # 0 #; # LOC VALUE FOR PRIMARY #
  253. DEF SEC1 # 1 #; # LOC VALUE FOR SECONDARY #
  254. DEF SEC # "SECOND" #;
  255.  
  256. ITEM COUPCNT; # NUMBER OF COUPLERS TO CURRENT NPU #
  257. ITEM I; # LOOP COUNTER #
  258. ITEM INRFLG B; # NODE NUMBER IN RANGE #
  259. ITEM KWD$MAP; # KEYWORD EXISTS BIT MAP #
  260. ITEM LOC$PAR C(10); # LOC PARAMETER VALUE #
  261. ITEM NODEVAL; # NODE VALUE #
  262. ITEM UNQFLG B; # NODE NUMBER UNIQUE FLAG #
  263.  
  264. SWITCH CPL$PAR ERR$CP , # UNK #
  265. NODE$ID, # NODE #
  266. ERR$CP , # VARIANT #
  267. ERR$CP , # OPGO #
  268. ERR$CP , # DMP #
  269. ERR$CP , # LLNAME #
  270. ERR$CP , # UNK #
  271. ERR$CP , # UNK #
  272. ERR$CP , # UNK #
  273. ERR$CP , # UNK #
  274. HNAM$ID, # HANME #
  275. LOC$ID ; # LOC #
  276. CONTROL EJECT;
  277. # #
  278. # CODE BEGINS HERE #
  279. # #
  280.  
  281. CRNT$CPL = " ";
  282. CRNT$CNID = 0;
  283. CRNT$HNAM = " ";
  284. KWD$MAP = 0; # CLEAR BIT MAP #
  285. LOC$PAR = "PRIMARY"; # SET DEFAULT LOC VALUE #
  286. PLWC[0] = PLWC[0] +1;
  287. IF NOT STLBERR[1]
  288. THEN
  289. BEGIN
  290. PLNAME[PLWC[0]] = STLABEL[1];
  291. PLTYPE[PLWC[0]] = 0; # INDICATES THIS IS A COUPLER STMT #
  292. END
  293. PLNID1[PLWC[0]] = CRNT$NID;
  294. PLHNAME[PLWC[0]] = " "; #BLANK FILL HOST NAME BY DEFAULT#
  295. FOR I=FSTKID2 STEP 1 UNTIL STWC[0]
  296. DO
  297. BEGIN
  298. B<STKWID[I],1>KWD$MAP = 1; # SET BIT FOR KEYWORD #
  299. IF NOT STVLERR[I]
  300. THEN
  301. BEGIN
  302. IF STKWID[I] LS KID"NODE"
  303. OR STKWID[I] GR KID"LOC"
  304. THEN
  305. GOTO ERR$CP;
  306. ELSE
  307. GOTO CPL$PAR[STKWID[I]];
  308.  
  309. NODE$ID: # PARAMETER IS - NODE #
  310. NODEVAL = STVALNUM[I];
  311. CHKNODE(NODEVAL,MX$NODE,UNQFLG,INRFLG); #CK NODE NUMBER #
  312. IF UNQFLG AND INRFLG
  313. THEN
  314. PLHNID[PLWC[0]] = STVALNUM[I];
  315. CRNT$CPL = STLABEL[1];
  316. CRNT$CNID = STVALNUM[I];
  317. TEST I;
  318.  
  319. HNAM$ID: # NEXT PARAMETER = HNAME #
  320. PLHNAME[PLWC[0]] = STVALNAM[I];
  321. CRNT$HNAM = STVALNAM[I];
  322. IF PLNAME[PLWC[0]] EQ PLHNAME[PLWC[0]]
  323. THEN
  324. NDLEM2(ERR122,STLNUM[0],HNAME$PAR);
  325. TEST I;
  326.  
  327. LOC$ID:
  328. # NEXT PARAMETER = LOC #
  329. LOC$PAR = STVALNAM[I]; # SAVE LOC VALUE #
  330. IF STVALNAM[I] EQ SEC
  331. THEN
  332. PLLOC[PLWC[0]] = 1;
  333. TEST I;
  334.  
  335. ERR$CP:
  336. EPRC2[0] = "CPLERPR";
  337. MESSAGE(ABRTMSG2,0);
  338. ABORT;
  339. END
  340. END # I LOOP #
  341. IF B<KID"NODE",1>KWD$MAP NQ 1
  342. THEN # IF NODE NOT SPECIFIED, FLAG ERROR #
  343. NDLEM2(ERR103,STLNUM[0],NODE$PAR); # FLAG ERROR #
  344. IF (PLLOC[PLWC[0]] EQ PRI1
  345. AND PRI$USED)
  346. OR (PLLOC[PLWC[0]] EQ SEC1
  347. AND SEC$USED)
  348. THEN
  349. NDLEM2(ERR124,STLNUM[0],LOC$PAR); # FLAG ERROR-DUP LOC VALUE #
  350. IF CPL$CNT GQ 2
  351. THEN
  352. NDLEM2(ERR123,STLNUM[0],COUP$PAR); # FLAG ERROR-TOO MANY CPLER #
  353. CPL$CNT = CPL$CNT + 1; # INCREMENT COUPLER COUNT #
  354. IF PLLOC[PLWC[0]] EQ PRI1
  355. THEN
  356. PRI$USED = TRUE;
  357. ELSE
  358. SEC$USED = TRUE;
  359. RETURN;
  360.  
  361. END # CPLERPR PROC #
  362.  
  363. CONTROL EJECT;
  364. PROC LLINKPR; # PROCESS LOGLINK STATEMENT #
  365. BEGIN
  366. *IF,DEF,IMS
  367. #
  368. ** LLINKPR - LOGICAL LINK PROCESSOR
  369. *
  370. * S.M. ILMBERGER 81/10/30
  371. *
  372. * PROCESS LOGICAL LINK STATEMENTS AND BUILD LOGLINK$XREF TABLE
  373. *
  374. * PROC LLINKPR
  375. *
  376. * ENTRY NONE
  377. *
  378. * EXIT NONE
  379. *
  380. * MESSAGES
  381. * INVALID KEYWORD I.D.-ABORT FRM LLINKPR
  382. *
  383. * METHOD
  384. *
  385. * IF NO LABEL ERROR
  386. * SAVE LOGLINK NAME IN LOGLINK$XREF TABLE
  387. * SAVE CURRENT NPU NODE AND CURRENT COUPLER NODE IN LOGLINK$XREF
  388. * FOR EACH PARAMETER ON THE LOGLINK LINE
  389. * SET APPROPRIATE BIT IN KEYWORD BITMAP
  390. * IF NO VALUE ERROR
  391. * IF PARAMETER IS NCNAME
  392. * SEARCH NPU$TABLE FOR NPU NAME = NCNAME VALUE
  393. * IF NCNAME VALUE IS A NPU NAME
  394. * SAVE CORRESPONDING NODE ID IN LOGLINK$XREF
  395. * ELSE
  396. * SEARCH COUP$TABLE FOR COUPLER NAME = NCNAME
  397. * IF NAME DEFINED IN COUPLER TABLE
  398. * SAVE CORRESPONDING NODE ID IN LOGLINK$XREF
  399. * ELSE
  400. * FLAG ERROR - INVALID NCNAME
  401. * IF DUPLICATE LOGLINK
  402. * FLAG ERROR - DUP LOGLINK
  403. * IF PARAMETER IS DI
  404. * SET FLAG IN LOGLINK$XREF TABLE
  405. * IF PARAMETER IS NOT DI OR NCNAME
  406. * SEND DAYFILE ERROR MESSMGE - ABORT
  407. * IF NCNAME PARAMETER NOT SPECIFIED
  408. * FLAG ERROR - PARAMETER MISSING
  409. * END
  410. *
  411. #
  412. *ENDIF
  413.  
  414. XREF
  415. BEGIN
  416. PROC NDLEM2; # MAKE ENTRY IN PASS 2 ERROR FILE #
  417. END
  418.  
  419. DEF DI$YES # "YES" #; # VALUE FOR DI PARAMETER #
  420. DEF LLNK$PAR # "LOGLINK" #;
  421. DEF NCNM$PAR # "NCNAME" #; # FOR ERROR MSG #
  422.  
  423. ITEM CPL$ENT; # ENTRY OF COUPLER TABLE #
  424. ITEM FOUND B; # FOUND FLAG #
  425. ITEM I; # LOOP COUNTER #
  426. ITEM J; # LOOP COUNTER #
  427. ITEM KWD$MAP; # KEYWORD EXISTS MAP #
  428. ITEM NPU$ENT; # ENTRY OF NPU TABLE #
  429.  
  430. SWITCH LLK$PAR ERR$LL , # UNK #
  431. ERR$LL , # NODE #
  432. ERR$LL , # VARIANT #
  433. ERR$LL , # OPGO #
  434. ERR$LL , # DMP #
  435. ERR$LL , # LLNAME #
  436. ERR$LL , # #
  437. ERR$LL , # #
  438. ERR$LL , # #
  439. ERR$LL , # #
  440. ERR$LL , # HNAME #
  441. ERR$LL , # LOC #
  442. ERR$LL , # #
  443. ERR$LL , # #
  444. ERR$LL , # #
  445. ERR$LL , # #
  446. ERR$LL , # #
  447. ERR$LL , # #
  448. NCNA$ID, # NCNAME #
  449. DI$ID ; # DI #
  450. CONTROL EJECT;
  451. # #
  452. # CODE BEGINS HERE #
  453. # #
  454.  
  455. KWD$MAP = 0; # CLEAR KEYWORD EXISTS MAP #
  456. LLWC[0] = LLWC[0] + 1;
  457. IF NOT STLBERR[1]
  458. THEN
  459. BEGIN # NO LABEL ERROR #
  460. LLNAME[LLWC[0]] = STLABEL[1]; # SET LLINK NAME #
  461. END
  462. LLHNID1[LLWC[0]] = CRNT$CNID;
  463. LLNID1[LLWC[0]] = CRNT$NID;
  464. LLHNAME[LLWC[0]] = CRNT$HNAM;
  465. FOR I=FSTKID2 STEP 1 UNTIL STWC[0]
  466. DO # PROCESS REST OF PARAMETERS #
  467. BEGIN
  468. B<STKWID[I],1>KWD$MAP = 1; # SET BIT FOR KEYWORD #
  469. IF NOT STVLERR[I]
  470. THEN
  471. BEGIN # NO VALUE ERRORS #
  472. IF STKWID[I] LS KID"NODE"
  473. OR STKWID[I] GR KID"DI"
  474. THEN
  475. GOTO ERR$LL;
  476. ELSE
  477. GOTO LLK$PAR[STKWID[I]];
  478.  
  479. NCNA$ID: # NEXT PARAMETER IS NCNAME #
  480. NPU$ENT = 0;
  481. FOR J=FSTNT STEP NTENTSZ WHILE NPU$ENT EQ 0
  482. AND J LQ NTWC[0]
  483. DO
  484. BEGIN
  485. IF NTNAME[J] EQ STVALNAM[I]
  486. THEN
  487. NPU$ENT = J;
  488. END # J LOOP #
  489. IF NPU$ENT GR 0
  490. THEN
  491. BEGIN
  492. LLHNID2[LLWC[0]] = NTNID[NPU$ENT];
  493. LLNID2[LLWC[0]] = NTNID[NPU$ENT];
  494. END
  495. ELSE
  496. BEGIN
  497. CPL$ENT = 0;
  498. FOR J=FSTCT STEP CTENTSZ WHILE CPL$ENT EQ 0
  499. AND J LQ CTENT[0]
  500. DO
  501. BEGIN # CHK COUPLER TABLE #
  502. IF CTNAME[J] EQ STVALNAM[I]
  503. THEN
  504. CPL$ENT = J;
  505. END # J LOOP #
  506. IF CPL$ENT GR 0
  507. THEN # NAME DEFINED IN COUPLER-TABLE #
  508. BEGIN
  509. LLTYPE[LLWC[0]] = 1;
  510. LLHNID2[LLWC[0]] = CTHNID[CPL$ENT];
  511. LLNID2[LLWC[0]] = CTNID[CPL$ENT];
  512. END
  513. ELSE
  514. NDLEM2(ERR121,STLNUM[0],NCNM$PAR);
  515. END
  516. IF LLHNID1[LLWC[0]] NQ 0
  517. AND LLHNID2[LLWC[0]] NQ 0
  518. THEN
  519. BEGIN
  520. FOR J=1 STEP 1 UNTIL LLWC[0] - 1
  521. DO
  522. BEGIN
  523. IF ( LLHNID1[J] EQ LLHNID1[LLWC[0]]
  524. AND LLHNID2[J] EQ LLHNID2[LLWC[0]] )
  525. OR ( LLHNID1[J] EQ LLHNID2[LLWC[0]]
  526. AND LLHNID2[J] EQ LLHNID1[LLWC[0]] )
  527. THEN
  528. BEGIN
  529. NDLEM2(ERR120,STLNUM[0],LLNK$PAR);
  530. END
  531. END # J LOOP #
  532. END
  533. TEST I;
  534.  
  535. DI$ID: # NEXT PARAMETER = DI #
  536. IF STVALNAM[I] EQ DI$YES
  537. THEN
  538. LLST[LLWC[0]] = TRUE;
  539. TEST I;
  540.  
  541. ERR$LL:
  542. EPRC2[0] = "LLINKPR";
  543. MESSAGE(ABRTMSG2,0);
  544. ABORT;
  545. END
  546. END # I LOOP #
  547.  
  548. IF B<KID"NCNAME",1>KWD$MAP NQ 1
  549. THEN # IF NCNAME NOT SPECIFIED, FLAG ERROR #
  550. NDLEM2(ERR103,STLNUM[0],NCNM$PAR);
  551.  
  552. IF LLNID1[LLWC[0]] NQ LLNID2[LLWC[0]] AND
  553. (LLNID1[LLWC[0]] NQ 0 AND LLNID2[LLWC[0]] NQ 0)
  554. THEN # IF THIS IS A LOGLINK TO A REMOTE NODE #
  555. BEGIN # AND NPU NODE I.D.-S WERE DETERMINED #
  556. FOUND = FALSE; # CLEAR FOUND FLAG #
  557. FOR I=1 STEP TNIENTSZ WHILE NOT FOUND AND
  558. I LQ TNIWC[0]
  559. DO # FOR EACH ENTRY IN THE TNI TABLE #
  560. BEGIN
  561. IF (LLNID1[LLWC[0]] EQ TNIN1[I] AND
  562. LLNID2[LLWC[0]] EQ TNIN2[I]) OR
  563. (LLNID1[LLWC[0]] EQ TNIN2[I] AND
  564. LLNID2[LLWC[0]] EQ TNIN1[I])
  565. THEN # IF TRUNK SUPPORTS LOGLINK #
  566. BEGIN
  567. FOUND = TRUE; # SET FOUND FLAG #
  568. END
  569. END
  570. IF NOT FOUND # IF NO TRUNK FOUND #
  571. THEN
  572. BEGIN # FLAG ERROR -- NO TRUNK FOR THIS LOGLINK #
  573. NDLEM2(ERR154,STLNUM[0]," ");
  574. END
  575. END
  576. RETURN;
  577.  
  578. END # LLINKPR PROC #
  579.  
  580. CONTROL EJECT;
  581. PROC NFILEPR; # PROCESS NFILE STATEMENT #
  582.  
  583. BEGIN
  584. *IF,DEF,IMS
  585. #
  586. ** NFILEPR - NFILE STATEMENT PROCESSOR
  587. *
  588. * S.M. ILMBERGER 81/11/2
  589. *
  590. * PROCESS NFILE STATEMENT
  591. *
  592. * PROC NFILEPR
  593. *
  594. * ENTRY NONE
  595. *
  596. * EXIT NONE
  597. *
  598. * MESSAGES NONE
  599. *
  600. * METHOD
  601. *
  602. * IF NO LABEL ERROR
  603. * INITIALIZE NCFFET
  604. * SET UP PRFX$TABLE
  605. * SET UP VERIFY$ENTRY TABLE
  606. * INITIALIZE NCF$INDEX TABLE
  607. * IF LABEL ERROR
  608. * CLEAR FILE NAME IN FET
  609. * END
  610. *
  611. #
  612. *ENDIF
  613. XREF
  614. BEGIN
  615. FUNC EDATE C(10); # UNPACK DATE #
  616. FUNC ETIME C(10); # UNPACK TIME #
  617. PROC PDATE; # GET PACKED DATE AND TIME #
  618. PROC RECALL; # RETURNS CONTROL WHEN PROCESS FINISHED #
  619. PROC REWIND; # REWINDS SPECIFIED FILE #
  620. PROC VERSION; # GET VERSION NUMBER OF OPERATING SYSTEM #
  621. PROC NDLZFIL; # ZERO FILL UNUSED PART OF WORD #
  622. END
  623.  
  624. DEF BLANK # " " #;
  625.  
  626. *CALL NAMLEV
  627.  
  628. ITEM I; # LOOP COUNTER #
  629. ITEM J; # DUMMY VARIBLE #
  630. ITEM TEMP1 U; # TEMP STORAGE #
  631. ITEM TEMPACDAT U; # STORAGE FOR PACKED DATE #
  632. ITEM TEMPDAT C(10); # STORAGE FOR DATE #
  633. ITEM TEMPNAM C(10); # STORAGE FOR NDLZFIL #
  634. ITEM TEMPT1 C(10); # STORAGE FOR TIME #
  635. ITEM TEMPTIM U; # STORAGE FOR TIME #
  636. ITEM TEMPVER C(10); # STORAGE FOR VERSION NO. OF OP. SYSTEM #
  637.  
  638. ARRAY TEMPTAB [0:0] S(1);
  639. BEGIN
  640. ITEM BC U(0,0,12); # NUMBER OF 12 BIT BYTES TO RETURN #
  641. ITEM SB U(0,12,12); # STARTING BYTE IN SOURCE FIELD #
  642. ITEM BP U(0,24,12); # STARTING BYTE IN RECEIVING FIELD #
  643. ITEM WADDR U(0,42,18); # ADDR OF FIELD RECEIVING VERSION NUMB #
  644. END
  645.  
  646. CONTROL EJECT;
  647. # #
  648. # CODE BEGINS HERE #
  649. # #
  650.  
  651. IF NOT STLBERR[1]
  652. THEN # NO LABEL ERROR #
  653. BEGIN
  654. PT$ID[0] = O"7700"; # SET TABLE I.D. #
  655. PTWC[0] = 0014; # SET WORD COUNT #
  656. PT$FNAME[0] = STLABEL[1]; # SET FILE HEADER NAME #
  657. TEMPNAM = STLABEL[1];
  658. NDLZFIL(TEMPNAM); # ZERO FILL FILE NAME #
  659. NCFLFN[0] = TEMPNAM; # INITIALIZE NCFFET #
  660. REWIND(NCFFET); # REWIND NCF FILE #
  661. RECALL(NCFFET);
  662. PDATE(TEMPACDAT); # GET PACKED DATE AND TIME #
  663. VEWORD1[0] = TEMPACDAT; # SET PAKED DATE-CLEARS REST OF WORD #
  664. TEMPTIM = 0;
  665. B<42,18>TEMPTIM = B<42,18>TEMPACDAT;
  666. TEMPT1 = ETIME(TEMPTIM); # UNPACK TIME - STORE IN TABLE #
  667. PT$TIME[0] = C<1,8>TEMPT1;
  668. TEMP1 = 0;
  669. C<7,3>TEMP1 = C<4,3>TEMPACDAT; # SET UP FOR EDATE #
  670. TEMPDAT = EDATE(TEMP1); # UNPACK DATE #
  671. PT$DATE[0] = C<1,8>TEMPDAT; # SET DATE #
  672. BC[0] = 5; # SET UP FOR VERSION CALL #
  673. SB[0] = 0;
  674. BP[0] = 0;
  675. WADDR[0] = LOC(TEMPVER);
  676. VERSION(TEMPTAB); # GET VERSION OF OPERATING SYSTEM #
  677. PT$OPS[0] = TEMPVER; # PUT VERSION IN TABLE #
  678. PT$PNAME[0] = "NDLP";
  679. PT$PVER[0] = C<9,3>NAMVER[0]; # SET PROGRAM VERSION NUMBER #
  680. PT$PLEV[0] = C<2,3>NAMLV[0]; # SET PROGRAM LEVEL #
  681. PT$BLNK1[0] = BLANK; # CLEAR FIELD #
  682. PT$BLNK2[0] = BLANK;
  683. PT$TITLE[0] = TITLE$WORD[0];
  684.  
  685. # SET VERIFY TABLE ENTRIES #
  686.  
  687. VE$ID[0] = "VERSION"; # SET TABLE I.D. #
  688.  
  689. # INITIALIZE NCF DIRECTORY HEADER #
  690.  
  691. NCFWORD[0] = 0; # CLEAR FIRST WORD #
  692. NCF$RECID[0] = O"7000"; # SET RECORD I.D. #
  693. NCF$NAM[0] = "NCF"; # SET FILE IDENTIFIER #
  694. NCFWORD1[0] = 0; # CLEAR SECOND WORD #
  695.  
  696. END
  697. ELSE
  698. BEGIN # LABEL ERROR EXISTS #
  699. NCFWORD0[0] = 0; # ZERO FILE NAME IN FET #
  700. END
  701. RETURN;
  702.  
  703. END # NFILEPR #
  704.  
  705. CONTROL EJECT;
  706. PROC NPUPR;
  707.  
  708. BEGIN
  709. *IF,DEF,IMS
  710. #
  711. ** NPUPR - NPU PROCESSOR
  712. *
  713. * S.M. ILMBERGER 81/11/2
  714. *
  715. * PROCESS NPU STATEMENT
  716. *
  717. * PROC NPUPR
  718. *
  719. * ENTRY NONE
  720. *
  721. * EXIT NONE
  722. *
  723. * MESSAGES
  724. * INVALID KEYWORD I.D.-ABORT FROM NPUPR
  725. *
  726. * METHOD
  727. *
  728. * IF NO LABEL ERROR
  729. * SAVE NPU NAME IN NPU$XREF TABLE
  730. * FOR EACH PARAMETER ON NPU STATEMENT
  731. * SET APPROPRIATE BIT IN KEYWORD BITMAP
  732. * IF NO VALUE ERROR
  733. * STORE PARAMETER VALUE IN APPROPRIATE NPU$XREF ITEM
  734. * ELSE VALUE ERROR EXISTS
  735. * SEND DAYFILE MESSAGE - ABORT
  736. * IF NODE OR VARIANT PARAMETER NOT SPECIFIED
  737. * FLAG ERROR - MISSING PARAMETER
  738. * CK IF SUPERVISORY LINK EXISTS FOR CURRENT NPU
  739. * IF NO SUPLINK STATEMENT
  740. * COUNT NUMBER OF LOGLINKS
  741. * IF MORE THAN ONE LOGLINK
  742. * FLAG ERROR - MISSING SUPLINK STATEMENT
  743. * IF NO LOGLINKS
  744. * FLAG ERROR - NO LOGLINKS TO NPU
  745. * ELSE
  746. * MAKE DEFAULT SUPLINK TABLE ENTRY
  747. * END
  748. *
  749. #
  750. *ENDIF
  751. XREF
  752. BEGIN
  753. PROC NDLEM2; # NMAKE ENTRY IN ERROR-FILE-2 #
  754. END
  755.  
  756. DEF LLINK$STMT # "LOGLINK" #;
  757. DEF MXNODE # 255 #; # MAX NODE NUMBER ON NPU STATEMENT #
  758. DEF NODE$PARAM # "NODE" # ;
  759. DEF SLINK$STMT # "SUPLINK" #;
  760. DEF VARI$PARAM # "VARIANT" #;
  761.  
  762. ITEM FOUND B;
  763. ITEM I; # LOOP COUNTER #
  764. ITEM INDEX;
  765. ITEM KWD$MAP; # KEYWORD EXISTS BIT MAP #
  766. ITEM NODE$INR B; # TRUE WHEN NODE NUMBER IS IN RANGE #
  767. ITEM NODE$UNQ B; # TRUE WHEN NODE NUMBER IS UNIQUE #
  768. ITEM NUMLLINK I; # NUMBER OF LOGLINKS TO THIS NPU #
  769. ITEM SPL$EXST B; # TRUE WHEN SUPLINK EXISTS FOR THIS NPU #
  770. ITEM DMP$USED B; # DMP SPECIFIED FLAG #
  771.  
  772. SWITCH NPU$PAR ERR$NPU, # UNK #
  773. NODE$ID, # NODE #
  774. VARI$ID, # VARIANT #
  775. OPGO$ID, # OPGO #
  776. DMP$ID; # DMP #
  777. CONTROL EJECT;
  778. # #
  779. # CODE BEGINS HERE #
  780. # #
  781.  
  782. NPWC[0] = NPWC[0] + 1;
  783. CRNT$CPL = " ";
  784. CRNT$CNID = 0;
  785. CPL$CNT = 0; # CLEAR COUPLER COUNT #
  786. KWD$MAP = 0; # CLEAR BIT MAP #
  787. PRI$USED = FALSE; # CLEAR LOC=PRIMARY SPECIFIED FLAG #
  788. SEC$USED = FALSE; # CLEAR LOC=SECOND SPECIFIED FLAG #
  789. DMP$USED = FALSE; # CLEAR DMP SPECIFIED FLAG #
  790. IF NOT STLBERR[1]
  791. THEN # NO LABEL ERROR EXISTS #
  792. BEGIN
  793. NPNAME[NPWC[0]] = STLABEL[1]; # PUT NPU NAME IN NPU$XREF #
  794. END
  795. FOR I=FSTKID2 STEP 1 UNTIL STWC[0]
  796. DO
  797. BEGIN
  798. B<STKWID[I],1>KWD$MAP = 1; # SET BIT FOR KEYWORD #
  799. IF NOT STVLERR[I] # NO VALUE ERROR #
  800. THEN
  801. BEGIN
  802. IF STKWID[I] LS KID"NODE"
  803. OR STKWID[I] GR KID"DMP"
  804. THEN
  805. GOTO ERR$NPU;
  806. ELSE
  807. GOTO NPU$PAR[STKWID[I]];
  808.  
  809. NODE$ID: # NEXT PARAMETER = NODE #
  810. CRNT$NPU = STLABEL[1];
  811. CRNT$NID = STVALNUM[I];
  812. CHKNODE(CRNT$NID,MXNODE,NODE$UNQ,NODE$INR); # CK NODE NUMB #
  813. IF NODE$UNQ AND NODE$INR
  814. THEN # NODE NUMBER UNIQUE AND IN RANGE #
  815. NPNID[NPWC[0]] = CRNT$NID; # SET NODE NUM IN NPU$XREF #
  816. TEST I;
  817.  
  818. VARI$ID: # NEXT PARAMETER = VARIANT #
  819. NPVARNT[NPWC[0]] = STVALNAM[I]; # SET VARIANT NUMBER IN #
  820. # NPU-XREF-TABLE #
  821. TEST I;
  822.  
  823. OPGO$ID: # NEXT PARAMETER = OPGO #
  824. IF STVALNAM[I] EQ "YES"
  825. THEN
  826. NPOPGO[NPWC[0]] = TRUE; # SET OPGO FLAG IN NPU$XREF TABLE #
  827. TEST I;
  828. DMP$ID: # NEXT PARAMETER = DMP #
  829. DMP$USED = TRUE; # SET DMP SPECIFIED FLAG TO TRUE #
  830. IF STVALNAM[I] EQ "YES" # IF VALUE IS -YES- #
  831. THEN
  832. BEGIN
  833. NPDMP[NPWC[0]] = TRUE; # SET DMP FLAG IN ENTRY #
  834. END
  835. TEST I;
  836.  
  837. ERR$NPU:
  838. EPRC2[0] = "NPUPR";
  839. MESSAGE(ABRTMSG2,0);
  840. ABORT;
  841. END
  842. END # I LOOP #
  843. IF NOT DMP$USED # IF DMP NOT SPECIFIED #
  844. THEN
  845. BEGIN
  846. NPDMP[NPWC[0]] = TRUE; # SET DMP FLAG IN ENTRY #
  847. END
  848. IF B<KID"NODE",1>KWD$MAP NQ 1
  849. THEN # IF -NODE- NOT SPECIFIED #
  850. NDLEM2(ERR103,STLNUM[0],NODE$PARAM); # FLAG ERROR #
  851. IF B<KID"VARIANT",1>KWD$MAP NQ 1
  852. THEN # IF -VARIANT- NOT SPECIFIED #
  853. NDLEM2(ERR103,STLNUM[0],VARI$PARAM); # FLAG ERROR #
  854. SPL$EXST = FALSE;
  855. FOUND = FALSE;
  856. FOR I=FSTNT STEP NTENTSZ UNTIL NTWC[0]
  857. DO
  858. BEGIN # SEE IF SUPLINK EXISTS #
  859. IF NOT FOUND
  860. THEN
  861. BEGIN
  862. IF NTNAME[I] EQ NPNAME[NPWC[0]]
  863. THEN
  864. BEGIN
  865. FOUND = TRUE;
  866. IF NTSPLK[I]
  867. THEN
  868. SPL$EXST = TRUE;
  869. END
  870. END
  871. END
  872. IF NOT SPL$EXST
  873. THEN # NO SUPLINK EXISTS #
  874. BEGIN # CHECK FOR MORE THAN 1 LOGLINK #
  875. NUMLLINK = 0;
  876. FOR I=FSTLLT STEP LLTENTSZ UNTIL LLTENT[0]
  877. DO # COUNT LLINKS #
  878. BEGIN
  879. IF LLTNID[I] EQ CRNT$NID
  880. THEN
  881. BEGIN
  882. NUMLLINK = NUMLLINK + 1;
  883. INDEX = I; # INDEX FOR LOGLINK TABLE #
  884. END
  885. END # I LOOP #
  886. IF NUMLLINK GR 1
  887. THEN # MORE THAN 1 LOGLINK EXISTS AND NO SLINK #
  888. NDLEM2(ERR126,STLNUM[0],SLINK$STMT);
  889. ELSE
  890. BEGIN
  891. IF NUMLLINK EQ 0
  892. THEN # NO LOGLINK TO THIS NPU #
  893. NDLEM2(ERR127,STLNUM[0],LLINK$STMT);
  894. ELSE # ONLY 1 LOGLINK TO THIS NPU #
  895. SLINKXR(INDEX); # MAKE DEFAULT SUPLINK TABLE ENTRY #
  896. END
  897. END
  898. RETURN;
  899.  
  900. END # NPUPR PROC #
  901.  
  902. CONTROL EJECT;
  903. PROC RNGNODE(NODEVAL,MAX,RNGFLG);
  904. # CHECK THAT NODE IS WITHIN RANGE #
  905. BEGIN # RNGNODE PROC #
  906. *IF,DEF,IMS
  907. #
  908. ** PRGNODE - CK RANGE OF NODE
  909. *
  910. * S.M. ILMBERGER 81/11/2
  911. *
  912. * CHECK THAT NODE VALUE IS WITHIN RANGE
  913. *
  914. * PROC RNGNODE(NODEVAL,MAX,RNGFLG)
  915. *
  916. * ENTRY NODEVAL - NODE NUMBER
  917. * MAX - MAXIMUM VALUE FOR NODE VALUE
  918. *
  919. * EXIT RNGFLG - FLAG INDICATING IF NODE VALUE IS IN RANGE
  920. *
  921. * MESSAGES NONE
  922. *
  923. * METHOD
  924. *
  925. * IF NODEVAL IS GREATER THAN MAX OR LESS THAN 0
  926. * SEND ERROR MESSAGE
  927. * SET RNGFLG TO FALSE
  928. * ELSE
  929. * SET RNGFLG TO TRUE
  930. * END
  931. *
  932. #
  933. *ENDIF
  934.  
  935. ITEM CNODE C(10); # CHARACTER STORAGE FOR NODE VALUE #
  936. ITEM NODEVAL I; # NODE NUMBER TO CHECK #
  937. ITEM MAX I; # MAX NUMBER FOR NODEVAL #
  938. ITEM RNGFLG B; # FLAG INDICATING NODE IS IN RANGE #
  939. # TRUE WHEN IN RANGE #
  940.  
  941. XREF
  942. BEGIN
  943. PROC NDLEM2; # MAKES ENTRY IN ERROR-FILE-2 #
  944. FUNC XCDD C(10); # CONVERT INTEGER TO DEC DISPLAY CODE #
  945. END
  946. CONTROL EJECT;
  947. # #
  948. # CODE BEGINS HERE #
  949. # #
  950.  
  951. IF NODEVAL GR MAX OR NODEVAL LQ 0
  952. THEN
  953. BEGIN # NODE NUMBER IS NOT IN RANGE #
  954. CNODE = XCDD(NODEVAL); # CONVERT INTEGER NODE TO CHARCATER #
  955. NDLEM2(ERR100,STLNUM[0],CNODE); # SEND ERROR MSG #
  956. RNGFLG = FALSE; # SET NODE IN RANGE FLAG TO FALSE #
  957. END
  958. ELSE
  959. RNGFLG = TRUE;
  960. RETURN; # *** RETURN *** #
  961.  
  962. END # RNGNODE PROC #
  963.  
  964. CONTROL EJECT;
  965. PROC SLINKPR;
  966. BEGIN # PROCESS SUPLINK STATEMENT #
  967. *IF,DEF,IMS
  968. #
  969. ** SLINKPR - SUPLINK PROCESSOR
  970. *
  971. * S.M. ILMBERGER 81/11/2
  972. *
  973. * PROCESS SUPLINK STATEMENT
  974. *
  975. * PROC SLINKPR
  976. *
  977. * ENTRY NONE
  978. *
  979. * EXIT NONE
  980. *
  981. * MESSAGES NONE
  982. *
  983. * METHOD
  984. *
  985. * FOR EACH KEYWORD ON STATEMENT
  986. * IF NO VALUE ERROR
  987. * IF KEYWORD = LLNAME
  988. * SEARCH LOGLINK TABLE FOR LLNAME VALUE
  989. * IF LLNAME IN LOGLINK TABLE
  990. * IF CURRENT NPU NODE MATCHES LOGLINK ENTRY
  991. * BUILD SUPLINK TABLE ENTRY
  992. * ELSE
  993. * SEND ERROR MESSAGE - NO LOGLINK TO THIS NPU
  994. * ELSE
  995. * LLNAME NOT VALID LOGLINK
  996. * IF LLNAME PARAMETER NOT SPECIFIED
  997. * SEND ERROR MESSAGE - REQUIRED PARAMETER MISSING
  998. * END
  999. *
  1000. #
  1001. *ENDIF
  1002.  
  1003. XREF
  1004. BEGIN
  1005. PROC NDLEM2; # MAKES ENTRY IN PASS 2 ERROR FILE #
  1006. END
  1007.  
  1008. DEF LLNAME$PAR # "LLNAME" #; # USED FOR NDLEM2 #
  1009.  
  1010. ITEM I; # LOOP COUNTER #
  1011. ITEM J; # LOOP COUNTER #
  1012. ITEM LL$ENT; # LOGLINK TABLE ENTRY THAT MATCHES LLNAME #
  1013. ITEM LLNAME$FLG B; # LLNAME PARAMETER IS SPECIFIED IF SET #
  1014. CONTROL EJECT;
  1015. # #
  1016. # CODE BEGINS HERE #
  1017. # #
  1018.  
  1019. LLNAME$FLG = FALSE;
  1020. FOR I=FSTKID1 STEP 1 UNTIL STWC[0]
  1021. DO
  1022. BEGIN
  1023. LLNAME$FLG = TRUE; # SET LLNAME SPECIFIED FLAG #
  1024. IF NOT STVLERR[I]
  1025. THEN # NO VALUE ERROR EXISTS #
  1026. BEGIN
  1027. IF STKWID[I] EQ KID"LLNAME"
  1028. THEN # NEXT KEYWORD = LLNAME #
  1029. BEGIN
  1030. LL$ENT = 0;
  1031. FOR J=FSTLLT STEP LLTENTSZ UNTIL LLTENT[0]
  1032. DO # SEARCH LOGLINK TABLE FOR SAME LLNAME #
  1033. BEGIN
  1034. IF LLTNAME[J] EQ STVALNAM[I]
  1035. THEN
  1036. LL$ENT = J;
  1037. END
  1038. IF LL$ENT NQ 0
  1039. THEN # FOUND LLNAME IN LOGLINK TABLE #
  1040. BEGIN
  1041. IF LLTNID[LL$ENT] EQ CRNT$NID
  1042. THEN # CURRENT NPU NODE MATCHES LOGLINK ENTRY #
  1043. SLINKXR(LL$ENT); # BUILD SUPLINK TABLE ENTRY #
  1044. ELSE
  1045. NDLEM2(ERR128,STLNUM[0],STVALNAM[I]);
  1046. END
  1047. ELSE # LLNAME NOT IN LOGLINK TABLE #
  1048. NDLEM2(ERR129,STLNUM[0],STVALNAM[I]);
  1049. END
  1050. END # NO VALUE ERROR #
  1051. END # I LOOP #
  1052. IF NOT LLNAME$FLG # LLNAME PARAMETER NOT SPECIFIED ON SUPLNK#
  1053. THEN # STATEMENT #
  1054. NDLEM2(ERR103,STLNUM[0],LLNAME$PAR);
  1055. RETURN;
  1056.  
  1057. END # SLINKPR PROC #
  1058.  
  1059. CONTROL EJECT;
  1060. PROC SLINKXR(LLENT); # MAKES ENTRIES IN SUPLINK TABLE #
  1061. BEGIN
  1062. *IF,DEF,IMS
  1063. #
  1064. ** SLINKXR - SUPLINK CROSS REFERINCE
  1065. *
  1066. * S.M. ILMBERGER 81/11/2
  1067. *
  1068. * MAKE ENTRIES IN SUPLINK TABLE
  1069. *
  1070. * PROC SLINKXR(LLENT)
  1071. *
  1072. * ENTRY LLENT - NUMBER ASSOCIATED W/LOGLINK TABLE ENTRY
  1073. *
  1074. * EXIT NONE
  1075. *
  1076. * MESSAGES NONE
  1077. *
  1078. * METHOD
  1079. *
  1080. * SET SUPLINK TABLE NAME AND HOST NODE FROM LOGLINK ENTRY
  1081. * SEARCH COUPLER TABLE TO SEE IF SUPLINK IS LOCAL OR REMOTE
  1082. * SET SUPLINK TYPE
  1083. * END
  1084. *
  1085. #
  1086. *ENDIF
  1087.  
  1088. ITEM LLENT; # NUMBER ASSOCIATED W/LLINK TABLE ENTRY #
  1089.  
  1090. DEF REMOTE # 1 #; # NPU IS REMOTE TO NPU #
  1091.  
  1092. ITEM K; # LOOP COUNTER #
  1093. ITEM MATCH B; # INDICATES COUPLER TABLE ENTRY AND #
  1094. # SUPLINK TABLE ENTRY MATCH #
  1095. ITEM NENTSL; # NEXT ENTRY IN SUPLINK TABLE #
  1096. CONTROL EJECT;
  1097. # #
  1098. # CODE BEGINS HERE #
  1099. # #
  1100.  
  1101. NENTSL = SLTWC[0] + 1; # MAKE ENTRIES IN SUPLINK TABLE #
  1102. SLTNAME[NENTSL] = LLTNAME[LLENT];
  1103. SLTHNID[NENTSL] = LLTHNID[LLENT];
  1104. SLTNID[NENTSL] = CRNT$NID;
  1105. MATCH = FALSE;
  1106. FOR K=FSTCT STEP CTENTSZ WHILE K LQ CTENT[0] AND NOT MATCH
  1107. DO # SEARCH COUPLER TABLE TO DETERMINE IF #
  1108. BEGIN # SUPLINK IS LOCAL OR REMOTE TO THIS NPU #
  1109. IF CTHNID[K] EQ SLTHNID[NENTSL]
  1110. AND CTNID[K] EQ CRNT$NID
  1111. THEN
  1112. BEGIN
  1113. MATCH = TRUE;
  1114. END
  1115. END
  1116. IF NOT MATCH
  1117. THEN
  1118. SLTTYPE[NENTSL] = REMOTE; # SET SUPLINK TYPE TO "REMOTE" #
  1119. SLTWC[0] = SLTWC[0] + SLTENTSZ;
  1120. RETURN;
  1121.  
  1122. END # SLINKXR #
  1123.  
  1124. CONTROL EJECT;
  1125. # #
  1126. # CODE BEGINS HERE #
  1127. # #
  1128.  
  1129. FOR I=0 WHILE STMT$STAT EQ TRNS$OK #STMT IS NETWORK ELEMENT TYPE #
  1130. AND (STMT$TYPE[STSTID[0]] EQ "NETWORK" # AND NO READ ERRORS #
  1131. OR STMT$TYPE[STSTID[0]] EQ "TRUNK")
  1132. DO
  1133. BEGIN
  1134. READW(STFET,STMT$TABLE[1],STWC[0],STMT$STAT); # READ FULL STMT #
  1135. IF STMT$STAT NQ TRNS$OK
  1136. THEN
  1137. GOTO ERR$NET;
  1138. ELSE
  1139. GOTO NET$ELEM[STSTID[0]];
  1140.  
  1141. NFILE$ST:
  1142. PTWORD0[0] = 0; # CLEARS WORD 0 OF PRFX$TABLE TABLE #
  1143. PTWORD1[0] = 0; # CLEARS WORD 1 OF PRFX$TABLE TABLE #
  1144. VEWORD0[0] = 0; # CLEARS VERIFY$ENTRY TABLE #
  1145. VEWORD1[0] = 0;
  1146. NFILEPR; # CALL NFILE STATEMENT PROCESSOR #
  1147. FWAWSA = LOC(PTWORD0[0]); #SAVE 1ST WORD ADDRESS OF FH TABLE #
  1148. NDLWNCF(TABLE"FH",FWAWSA,LEN$FH$TAB); # WRITE FILE HEADER REC #
  1149. GOTO RDNXT;
  1150.  
  1151. NPU$ST:
  1152. NPWORD[NPWC[0]+1] = 0; #CLEAR NEXT 2 WORDS OF NPU$XREF TABLE #
  1153. NPWORD1[NPWC[0]+1] = 0;
  1154. NPUPR; # CALLS NPU STATEMENT PROCESSOR #
  1155. GOTO RDNXT;
  1156.  
  1157. SLINK$ST:
  1158. IF ( SLTWC[0]+1+SLTENTSZ ) GR SLT$LENG
  1159. THEN # NOT ENOUGH SPACE IN SUPLINK$TAB #
  1160. BEGIN
  1161. SSTATS(P<SUPLINK$TABL>,SLTENTSZ); # ALLOCATE 1 MORE WORD FOR #
  1162. END # SUPLINK TABLE #
  1163. SLTWORD[SLTWC[0]+1] = 0; # CLEARS NEW WORD OF TABLE #
  1164. SLINKPR; # CALL SUPLINK STMT PROCESSOR #
  1165. GOTO RDNXT;
  1166.  
  1167. COUP$ST:
  1168. IF ( (PLWC[0]*PLENTSZ)+1+PLENTSZ ) GR PL$LENG
  1169. THEN # NEED MORE SPACE IN PLINK$XREF TABLE #
  1170. BEGIN
  1171. SSTATS(P<PLINK$XREF>,PLENTSZ); # ALLOCATE 2 WORDS #
  1172. END
  1173. PLWORD[PLWC[0]+1] = 0; # CLEAR NEW TABLE ENTRIES #
  1174. PLWORD1[PLWC[0]+1] = 0;
  1175. CPLERPR; # CALL COUPLER PROCESSOR #
  1176. GOTO RDNXT;
  1177.  
  1178. LLINK$ST:
  1179. LLWORD[LLWC[0]+1] = 0; # CLEAR NEW TABLE ENTRIES #
  1180. LLWORD1[LLWC[0]+1] = 0;
  1181. LLINKPR; # CALL LOGLINK STMT PROCESSOR #
  1182. GOTO RDNXT;
  1183.  
  1184. TRNK$ST:
  1185. IF ( (PLWC[0]*PLENTSZ)+1+PLENTSZ ) GR PL$LENG
  1186. THEN # NEED MORE ROOM IN PLINK$XREF TABLE #
  1187. BEGIN
  1188. SSTATS(P<PLINK$XREF>,PLENTSZ); # ALLOCATE 2 MORE WORDS #
  1189. END
  1190. PLWORD[PLWC[0]+1] = 0; # CLEAR NEW TABLE ENTRIES #
  1191. PLWORD1[PLWC[0]+1] = 0;
  1192. NDLTRNK; # CALL TRUNK STMT PROCESSOR #
  1193. GOTO RDNXT;
  1194.  
  1195. ERR$NET:
  1196. EPRC1[0] = "NCFNET";
  1197. MESSAGE(ABRTMSG1,0);
  1198. ABORT;
  1199. TEST I;
  1200.  
  1201. RDNXT:
  1202. READW(STFET,STMT$TABLE,1,STMT$STAT); # READ NXT STMT HEADER #
  1203. TEST I;
  1204. END # I LOOP #
  1205. RETURN;
  1206.  
  1207. END # NDLNFNT #
  1208. TERM
cdc/nos2.source/nam5871/ndlnfnt.txt ยท Last modified: 2023/08/05 17:22 by Site Administrator