clafer-0.3.7: clafer compiles Clafer models to other formats, such as Alloy, XML, HTML, Dot.

Safe HaskellNone
LanguageHaskell2010

Language.Clafer.JSONMetaData

Description

Creates JSON outputs for different kinds of metadata.

Synopsis

Documentation

generateJSONnameUIDMap :: QNameMaps -> String Source

Generate a JSON list of triples containing a fully-qualified-, least-partially-qualified name, and unique id. | Both the FQNames and UIDs are brittle. LPQNames are the least brittle.

generateJSONScopes :: QNameMaps -> [(UID, Integer)] -> String Source

Generate a JSON list of tuples containing a least-partially-qualified name and a scope

parseJSONScopes :: QNameMaps -> String -> [(UID, Integer)] Source

given the QNameMaps, parse the JSON scopes and return list of scopes

writeCfrScopeFile :: [(UID, Integer)] -> QNameMaps -> FilePath -> IO () Source

Write a .cfr-scope file

readCfrScopeFile :: QNameMaps -> FilePath -> IO (Maybe [(UID, Integer)]) Source

Read a .cfr-scope file