hetdg.hs revision 306763c67bb99228487345b32ab8c5c6cd41f23c
8b054cade993ef373d564b2d74c9c5a2da48f8b7Kristina SojakovaModule : $Header$
e9458b1a7a19a63aa4c179f9ab20f4d50681c168Jens ElknerCopyright : (c) Till Mossakowski, Uni Bremen 2002-2004
097b7fb3f8f90e87120d30bf37a1d89fe0ddfaf0Kristina SojakovaLicence : similar to LGPL, see HetCATS/LICENCE.txt or LIZENZ.txt
94e2e03f6efde106de095ef4ea0ec87f74955a31Kristina SojakovaMaintainer : hets@tzi.de
98890889ffb2e8f6f722b00e265a211f13b5a861Corneliu-Claudiu ProdescuStability : provisional
211c5fb252e0a776baad9a4857ab198659289a4aKristina SojakovaPortability : non-portable(via imports
211c5fb252e0a776baad9a4857ab198659289a4aKristina Sojakova Temporary interface for displaying development graphs.
211c5fb252e0a776baad9a4857ab198659289a4aKristina Sojakova Should be replaced with hets in the future.
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakova-- needs ghc and UniForM workbench
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakova-- for the UniForM workbench:
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakova-- cd into the folder where HetCATS lives
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakova-- gmake packages
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakovaimport DaVinciGraph
8b054cade993ef373d564b2d74c9c5a2da48f8b7Kristina Sojakovaimport GraphDisp
2c47bb55d963ff37dbae4a0a7701274fddb95fc8Christian Maederproceed fname showdg = do
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakova res <- anaFile logicGraph defaultLogic defaultHetcatsOpts emptyLibEnv fname
8b054cade993ef373d564b2d74c9c5a2da48f8b7Kristina Sojakova Just (ln,_,dg,libenv) ->
9d770d1ea15092156d65e2a89b081eeeb8c6b153Kristina Sojakova if showdg then do
2c47bb55d963ff37dbae4a0a7701274fddb95fc8Christian Maeder graphMem <- initializeConverter
1a38107941725211e7c3f051f7a8f5e12199f03acmaeder (gid,gv,cmaps) <- convertGraph graphMem ln libenv
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakova h <- openFile (fname++".dot") WriteMode
b5702fcfbabcc2b13557bc96ed8376133420dc73Kristina Sojakova sequence (map (hPutStrLn h) (dot dg))
1a38107941725211e7c3f051f7a8f5e12199f03acmaeder _ -> return ()
4e3744376d584470e1342cbac9ac27032f2045c3Christian Maeder args <- getArgs
2ddc9d39235393dca2e40203dde20284db4c3deeKristina Sojakova proceed (head args) (not ((tail args)==["-dot"]))