Every instance has readDataFromStream
and
writeDataToStream
methods. The second is usually applied to
forms, causing them to write the data from all their fields to a stream:
IncomeTax.TaxRate = 25 IncomeTax.TaxBands = 3WOM writes out the data one entry per line, as a path/value pair.
readDataFromStream
reads back data into an instance. Both methods
have options for controlling the format of paths, what to do if a path
that doesn't exist is read, and so on. Our economic models (written in
Modula-2) have a library of routines for reading and writing files in
this format, so it is easy to pass data to and from these programs. We
also have special classes for merging WOM data files and for storing the
data in memory.