DirectoryList.mesa
Michael Plass, April 8, 1983 11:42 am
For listing local or remote file directories.
DIRECTORY Rope;
DirectoryList: CEDAR DEFINITIONS ~ BEGIN
ROPE: TYPE ~ Rope.ROPE;
NeverAbort: PROCEDURE RETURNS [BOOLEAN];
Remote: PROCEDURE [host: ROPE, pattern: ROPE, abortProc: PROC RETURNS [BOOLEAN] ← NeverAbort] RETURNS [matchingFiles: LIST OF ROPE, errorMsg: ROPE];
host is simply the name of the host.
pattern is an ftp-style pattern, e.g., <foo*>bar.*
The matching files are returned as, e.g., LIST["<foo1>bar.mesa!1", "<foo2>bar.bcd!2"]
Local: PROCEDURE [pattern: ROPE, abortProc: PROC RETURNS [BOOLEAN] ← NeverAbort] RETURNS [matchingFiles: LIST OF ROPE];
pattern may contain * wildcards.
END.