Trailing-Edge
-
PDP-10 Archives
-
decuslib20-03
-
decus/20-0078/util/multi.sim
There is 1 other file named multi.sim in the archive. Click here to see a list.
BEGIN
EXTERNAL REF (Infile) PROCEDURE findinfile;
EXTERNAL REF (Directfile) PROCEDURE finddirectfile;
EXTERNAL REF (Outfile) PROCEDURE findoutfile;
EXTERNAL TEXT PROCEDURE front,scanto,getitem;
EXTERNAL INTEGER PROCEDURE maxint,search,splita,hash,arrlgd;
EXTERNAL PROCEDURE split,arrtxt;
EXTERNAL BOOLEAN PROCEDURE puttext;
EXTERNAL TEXT PROCEDURE conc,upcase,frontstrip,rest,checkextension;
EXTERNAL CHARACTER PROCEDURE fetchar,findtrigger;
EXTERNAL LONG REAL PROCEDURE scanreal;
EXTERNAL INTEGER PROCEDURE checkreal,checkint,scanint,ilog;
EXTERNAL BOOLEAN PROCEDURE menu;
EXTERNAL CLASS safeio,simdbm;
simdbm("","","",68,TRUE) BEGIN
REF (basespec) dokbas,keybas;
REF (basespec) prevbase;
CLASS basespec(df,rl,top,gk,bs,bsc,arrc,stbuff,rslist,frl);
! for set handling: one more parameter:
ref (setspec) sslist;
REF (Directfile) df; INTEGER rl,top,gk; REF (rspec) rslist;
TEXT bs,arrc,stbuff; CHARACTER bsc; REF (ilist) frl;
BEGIN
PROCEDURE setbase;
BEGIN
! save again those variables which might have been
changed for the previous base;
INSPECT prevbase DO
BEGIN top:=oflowtop; gk:=gen_key; frl:-freelist; END;
prevbase:-THIS basespec;
d__file:-df; rlength:=rl; oflowtop:=top;
gen_key:=gk; backslash:-bs; cback:=bsc;
arrchar:-arrc; store_buff:-stbuff;
recordspec:-rslist; freelist:-frl;
! for set handling: stab:-sslist;
END setbase;
END basespec;
REF (basespec) PROCEDURE savebase;
savebase:-prevbase:-
NEW basespec(d__file,rlength,oflowtop,gen_key,backslash,
cback,arrchar,store_buff,recordspec,freelist);
! for set handling, one more parameter: stab;
! ------------ START OF MAIN ----------------;
! example of two bases used in paralell by means of
the class BASESPEC and the procedure SAVEBASE;
! open bases and set pointers to their definitions;
openbase("padok.bas",238); dokbas:-savebase;
openbase("padkey.bas",78); keybas:-savebase;
! actualize base of documents, and read one document;
dokbas.setbase;
tabulate(get("19645","DOKUMENT"));
! actualize base of keywords and read one keyword record;
keybas.setbase;
tabulate(get("BOK","KEYWORD"));
closebase;
dokbas.setbase; closebase;
eof:
END;
END;