/* VPIPEINC REXX A1 */; /* Created on 17 Nov 1986 at 19:41:53 */; /* by Brent Longborough (BRENT at RIOVMBHQ) */; /* Process and expands include records in a Vertical Pipeline */; /* Format: VPIPEINC */; /* where */; /* */; /* Rstring is used to trap recursive includes, and should not be used */; /* other than in the recursive call used by VPIPEINC itself. */; /* */; /* Records on input stream 0 are copied to output, unless the first */; /* word in the record is "%". In this case, the second word is */; /* assumed to be the filename of an imbedded Vertical Pipeline, and */; /* is included in the stream. Trigger records in the imbedded file */; /* are also interpreted - VPIPEINC does not impose a limit on depth, */; /* other than to protect against recursion. */; ; Parse Source System Type Fn Ft Fm Myself .; Arg Rstring; Trig = '%'; Dft = 'VPIPE'; Dfm = '*'; Do Until Rc /= 0; 'READTO Buffer'; If Rc = 0; Then Do; If Trig /= Word(Buffer,1); Then; 'OUTPUT' Buffer; Else Do; Parse Upper Var Buffer . Fn .; If Fn = ''; Then Leave; If 0 = Find(Rstring,Fn); Then; 'CALLPIPE <' Fn DFt DFm, ' |' Myself Rstring Fn, ' |*.Output:'; End; End; End; Rc = Rc * (Rc /= 12); Exit Rc;