|An experimental monadic interface to Tree mutation. The main idea is to
simulate IO-ish manipulation of real filesystem (that's the state part of
the monad), and to keep memory usage down by reasonably often dumping the
intermediate data to disk and forgetting it. XXX This currently does not
work as advertised and the monads leak memory. So far, I'm at a loss why
|=> TreeIO a||action
|-> IO (a, Tree)|
Run a TreeIO action in a hashed setting. The initial tree is assumed
to be fully available from the directory, and any changes will be written
out to same. Please note that actual filesystem files are never removed.
XXX This somehow manages to leak memory, somewhere.
|Run a TreeIO action in a plain tree setting. Writes out changes to the
plain tree every now and then (after the action is finished, the last tree
state is always flushed to disk). XXX Modify the tree with filesystem
reading and put it back into st (ie. replace the in-memory Blobs with normal
ones, so the memory can be GCd).
|Run a TreeIO action without dumping anything to disk. Useful for running
tree mutations just for the purpose of getting the resulting Tree and
throwing it away.
|Grab content of a file in the current Tree at the given path.
|Change content of a file at a given path. The change will be eventually
flushed to disk, but might be buffered for some time.
|Check for existence of a file.
|Check for existence of a node (file or directory, doesn't matter).
|Internal state of the TreeIO monad. Keeps track of the current Tree
content, unsync'd changes and a current working directory (of the monad).
|A TreeIO monad. A sort of like IO but it keeps a TreeState around as well,
which is a sort of virtual filesystem. Depending on how you obtained your
TreeIO, the actions in your virtual filesystem get somehow reflected in the
actual real filesystem. For virtualTreeIO, nothing happens in real
filesystem, however with plainTreeIO, the plain tree will be updated every
now and then, and with hashedTreeIO a darcs-style hashed tree will get
|Produced by Haddock version 2.4.2|