| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
OrgStat.Scope
Description
This module defines how report input is formed.
- newtype AstPath = AstPath {
- getAstPath :: [Text]
- isSubPath :: AstPath -> AstPath -> Bool
- existsPath :: AstPath -> Org -> Bool
- data ScopeModifier
- applyModifiers :: Org -> [ScopeModifier] -> Either ModifierError Org
Documentation
Path in org AST is just a list of paths, head ~ closer to tree root.
Constructors
| AstPath | |
Fields
| |
data ScopeModifier Source #
Modificicators of org tree. They remove some subtrees
Constructors
| ModPruneSubtree AstPath Int | Turns all subtrees starting with |
| ModFilterTag Text | Given text tag name, it leaves only those subtrees that have this tag (tags are inherited). |
| ModSquash AstPath | Starting at node on path A and depth n, turn A into set of nodes Aa1a2...an. Doesn't work/make sense for empty path. |
| ModSelectSubtree AstPath | Leaves only node at |
Instances
applyModifiers :: Org -> [ScopeModifier] -> Either ModifierError Org Source #
Generates an org to be processed by report generators from Scope.