Copyright | (c) Marien Matser Gerard van Schie Jelle Teeuwissen 2022 |
---|---|
License | MIT |
Maintainer | jelleteeuwissen@hotmail.nl |
Stability | experimental |
Safe Haskell | None |
Language | Haskell2010 |
Documentation
apply :: [Operation] -> Rule -> Data -> Result Json Source #
Apply takes a list of operations, a rule and data. And together with the default operations evaluates it.
>>>
apply [] (read "{\"cat\":[\"Hello, \", \"World!\"]}":: Json) JsonNull
Right "Hello, World!"
applyEmpty :: [Operation] -> Rule -> Data -> Result Json Source #
applyEmpty takes a list of operations, a rule and data. And without the default operations evaluates it.
>>>
applyEmpty [] (read "{\"cat\":[\"Hello, \", \"World!\"]}":: Json) JsonNull
Left (UnrecognizedOperation {operationName = "cat"})