Maintainer | Andrei Costa <acosta@inf.ufrgs.br> |
---|---|
Stability | experimental |
Safe Haskell | Safe |
Language | Haskell2010 |
A grammar is defined as a start object, a set of transformation rules, and a set of constraints for the potencial generated objects. The morphism type is kept generic.
- grammar :: Obj m -> [Constraint m] -> [NamedProduction m] -> Grammar m
- data Grammar m
- data ObjectFlow m = ObjectFlow {}
- type RuleSequence m = (String, [(String, Production m)], [ObjectFlow m])
- type NamedProduction m = (String, Production m)
- getProductionName :: NamedProduction m -> String
- getProduction :: NamedProduction m -> Production m
- start :: Grammar m -> Obj m
- constraints :: Grammar m -> [Constraint m]
- rules :: Grammar m -> [NamedProduction m]
- findProduction :: String -> Grammar m -> Maybe (Production m)
- reachableGraphs :: Grammar m -> [(String, Obj m)]
- addReachableGraphs :: [(String, Obj m)] -> Grammar m -> Grammar m
Documentation
grammar :: Obj m -> [Constraint m] -> [NamedProduction m] -> Grammar m Source #
data ObjectFlow m Source #
Object that uses a Span of Morphisms to connect the right-hand-side of a Production with the left-hand-side of another one
ObjectFlow | |
|
type RuleSequence m = (String, [(String, Production m)], [ObjectFlow m]) Source #
type NamedProduction m = (String, Production m) Source #
getProductionName :: NamedProduction m -> String Source #
getProduction :: NamedProduction m -> Production m Source #
constraints :: Grammar m -> [Constraint m] Source #
rules :: Grammar m -> [NamedProduction m] Source #
findProduction :: String -> Grammar m -> Maybe (Production m) Source #