Init must be called before any other function in the module.
Readprotofile reads a file system prototype from the file proto . It traverses the file system, starting at the given root , and each file or directory encountered that is mentioned in the prototype causes readprotofile to send a Direntry tuple on the channel entries . The tuple has the form ( old , new , dir\f5) where old is the name of the current file or directory, rooted at root , new is the same file's name relative to root , and dir is a reference to the Sys->Dir directory information for old , as produced by sys-stat (2). When all files in root have been examined, readprotofile sends a single tuple with all nil components on entries . For each error that occurs during processing (eg, unable to open a directory) readprotofile sends a tuple ( old , diag ) on the channel warnings , naming the file and giving a diagnostic string, but processing continues.
Readprotostring reads a file system prototype from the string proto itself. Otherwise, its operation is the same as readprotofile .