------------------------------
-- cleanit
------------------------------

cleanit parseTree = do
 h <- openCleanOut
 prologue h
 cleanServers h parseTree
 cleanSegments h parseTree
 cleanConnect h
 cleanStopServers h parseTree
 cleanRemoveServers h parseTree
 cleanRemoveSegments h parseTree
 closeCleanOut h

------------------------------
-- functions called by cleanup
------------------------------
cleanit parseTree = do
 h <- openCleanOut
 prologue h
 cleanServers h parseTree
 cleanSegments h parseTree
 cleanConnect h
 cleanStopServers h parseTree
 cleanRemoveServers h parseTree
 cleanRemoveSegments h parseTree
 closeCleanOut h

------------------------------
-- functions called by cleanup
------------------------------
cleanit parseTree = do
 h <- openCleanOut
 prologue h
 cleanServers h parseTree
 cleanSegments h parseTree
 cleanConnect h
 cleanStopServers h parseTree
 cleanRemoveServers h parseTree
 cleanRemoveSegments h parseTree
 closeCleanOut h

------------------------------
-- functions called by cleanup
------------------------------