In order to provide easy transportability of data between different computer systems information stored in an RZ directory tree can be written to or read from a sequential file. All keys in the tree associated with the CWD can be copied to an FZ sequental file by using RZTOFZ. The sequential file must be opened with FZFILE prior to the call to RZTOFZ and thus the transport mode (native or exchange) is determined by the mode declared to FZFILE.
The data structures are read into the system division of the primary store before their transfer to the output file.
A directory tree can be read from an FZ sequential file into the CWD using the routine RZFRFZ. If a sub-directory with the same name as the one read in is already present in the CWD, then a new cycle is created for the introduced keys. The sequential file must be opened with FZFILE prior to the call to RZFRFZ and hence the transport format (native or exchange) is determined by the mode declared to FZFILE.