Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Defines printer types and functions for generating traceability graphs (as .dot files).
Synopsis
- type Colour = String
- type Label = String
- data NodeFamily = NF {}
- data GraphInfo = GI {
- assumpNF :: NodeFamily
- ddNF :: NodeFamily
- gdNF :: NodeFamily
- tmNF :: NodeFamily
- imNF :: NodeFamily
- reqNF :: NodeFamily
- gsNF :: NodeFamily
- chgNF :: NodeFamily
- edgesAvsA :: [(UID, [UID])]
- edgesAvsAll :: [(UID, [UID])]
- edgesRefvsRef :: [(UID, [UID])]
- edgesAllvsR :: [(UID, [UID])]
- edgesAllvsAll :: [(UID, [UID])]
- outputDot :: FilePath -> GraphInfo -> IO ()
- mkOutputAvsA :: GraphInfo -> IO ()
- mkOutputAvsAll :: GraphInfo -> IO ()
- mkOutputRefvsRef :: GraphInfo -> IO ()
- mkOutputAllvsR :: GraphInfo -> IO ()
- mkOutputAllvsAll :: GraphInfo -> IO ()
- mkOutput :: GraphInfo -> String -> (GraphInfo -> [(UID, [UID])]) -> [GraphInfo -> NodeFamily] -> IO ()
- outputSub :: Handle -> [(UID, [UID])] -> [NodeFamily] -> IO ()
- mkDirections :: Handle -> (UID, [UID]) -> IO ()
- mkNodes :: Handle -> NodeFamily -> IO ()
- mkSubgraph :: Handle -> Label -> [UID] -> IO ()
- filterAndGI :: GraphInfo -> [GraphInfo -> NodeFamily] -> [NodeFamily]
- filterInvalidChars :: String -> String
Types
data NodeFamily Source #
A node family contains a list of UID
s, their display labels, general subgraph label, and colour.
NF | |
|
Holds all important and relevant information for generating a traceability graph. Includes nodes, graph edges, and node family information.
GI | |
|
Functions
Main Outputs
outputDot :: FilePath -> GraphInfo -> IO () Source #
Creates the directory for output, gathers all individual graph output functions and calls them.
mkOutputAvsA :: GraphInfo -> IO () Source #
Output function for assumptions dependent on assumptions.
mkOutputAvsAll :: GraphInfo -> IO () Source #
Output function for definitions, models, requirements, and changes dependent on assumptions.
mkOutputRefvsRef :: GraphInfo -> IO () Source #
Output function for definitions and models that are dependent on other definitions and models.
mkOutputAllvsR :: GraphInfo -> IO () Source #
Output function for goals and requirements dependent on definitions, models, and other requirements.
mkOutputAllvsAll :: GraphInfo -> IO () Source #
Output function for definitions, models, requirements, goals, and changes that are dependent on one another.
Helpers
mkOutput :: GraphInfo -> String -> (GraphInfo -> [(UID, [UID])]) -> [GraphInfo -> NodeFamily] -> IO () Source #
General output function for making a traceability graph. Takes in the graph information, title, edge generator functions, and node family functions.
outputSub :: Handle -> [(UID, [UID])] -> [NodeFamily] -> IO () Source #
Graph output helper. Takes in the file handle, edges, and node families.
mkDirections :: Handle -> (UID, [UID]) -> IO () Source #
Prints graph edges (directions) onto a given file handle.
mkNodes :: Handle -> NodeFamily -> IO () Source #
Prints graph nodes (labels) onto a given file handle.
mkSubgraph :: Handle -> Label -> [UID] -> IO () Source #
Helper that only makes a subgraph if there are elements in the subgraph. Otherwise, it returns nothing.
filterAndGI :: GraphInfo -> [GraphInfo -> NodeFamily] -> [NodeFamily] Source #
Gets graph labels.
filterInvalidChars :: String -> String Source #
Helper to remove invalid characters.