Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Language.REST.Internal.WorkStrategy
Synopsis
- type GetWork m rule term oc = [Path rule term oc] -> ExploredTerms term oc m -> (Path rule term oc, [Path rule term oc])
- newtype WorkStrategy rule term oc = WorkStrategy (forall m. GetWork m rule term oc)
- bfs :: WorkStrategy rule term oc
- notVisitedFirst :: (Eq term, Eq rule, Eq oc, Hashable term) => WorkStrategy rule term oc
Documentation
type GetWork m rule term oc = [Path rule term oc] -> ExploredTerms term oc m -> (Path rule term oc, [Path rule term oc]) Source #
newtype WorkStrategy rule term oc Source #
WorkStrategy
defines the procedure for choosing which pending path REST explores
Constructors
WorkStrategy (forall m. GetWork m rule term oc) |
bfs :: WorkStrategy rule term oc Source #
Explore the rewrite tree in BFS style. Using this strategy enables finding the shortest rewrite path to a desired term.
notVisitedFirst :: (Eq term, Eq rule, Eq oc, Hashable term) => WorkStrategy rule term oc Source #
Prioritize searching for terms that haven't been seen before. This strategy may explore all reachable terms earlier, reducing the need to explore down the remaining unexplored paths.