-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | API for parsing "aeson" JSON tree into Haskell types
--
-- A flexible parser DSL of JSON AST produced by the "aeson" library with
-- automated and highly detailed error reporting. Provides a featureful
-- toolkit for parsing real-world documents with schemas of any
-- complexity or ambiguity, which the FromJSON instances are
-- simply not fit for.
@package aeson-value-parser
@version 0.19
module AesonValueParser
-- | JSON Value AST parser.
--
-- Its Alternative instance implements the logic of choosing
-- between the possible types of JSON values.
data Value a
run :: Value a -> Value -> Either Error a
runWithTextError :: Value a -> Value -> Either Text a
data Error
Error :: [Text] -> Text -> Error
object :: Object a -> Value a
array :: Array a -> Value a
null :: Value ()
nullable :: Value a -> Value (Maybe a)
nullableMonoid :: Monoid a => Value a -> Value a
string :: String a -> Value a
number :: Number a -> Value a
bool :: Value Bool
fromJSON :: FromJSON a => Value a
data String a
text :: String Text
matchedText :: (Text -> Either Text a) -> String a
attoparsedText :: Parser a -> String a
megaparsedText :: Parsec Void Text a -> String a
data Number a
scientific :: Number Scientific
integer :: (Integral a, Bounded a) => Number a
floating :: RealFloat a => Number a
matchedScientific :: (Scientific -> Either Text a) -> Number a
matchedInteger :: (Integral integer, Bounded integer) => (integer -> Either Text a) -> Number a
matchedFloating :: RealFloat floating => (floating -> Either Text a) -> Number a
-- | JSON Value parser.
data Object a
field :: Text -> Value a -> Object a
oneOfFields :: [Text] -> Value a -> Object a
fieldMap :: (Eq a, Hashable a) => String a -> Value b -> Object (HashMap a b)
foldlFields :: (state -> key -> field -> state) -> state -> String key -> Value field -> Object state
-- | JSON Value parser.
data Array a
element :: Int -> Value a -> Array a
elementVector :: Value a -> Array (Vector a)
foldlElements :: (state -> Int -> element -> state) -> state -> Value element -> Array state
foldrElements :: (Int -> element -> state -> state) -> state -> Value element -> Array state
instance Control.Monad.Error.Class.MonadError AesonValueParser.Error.Error AesonValueParser.Array
instance GHC.Base.MonadPlus AesonValueParser.Array
instance GHC.Base.Monad AesonValueParser.Array
instance GHC.Base.Alternative AesonValueParser.Array
instance GHC.Base.Applicative AesonValueParser.Array
instance GHC.Base.Functor AesonValueParser.Array
instance Control.Monad.Error.Class.MonadError AesonValueParser.Error.Error AesonValueParser.Object
instance GHC.Base.MonadPlus AesonValueParser.Object
instance GHC.Base.Monad AesonValueParser.Object
instance GHC.Base.Alternative AesonValueParser.Object
instance GHC.Base.Applicative AesonValueParser.Object
instance GHC.Base.Functor AesonValueParser.Object
instance GHC.Base.Alternative AesonValueParser.Number
instance GHC.Base.Applicative AesonValueParser.Number
instance GHC.Base.Functor AesonValueParser.Number
instance GHC.Base.Alternative AesonValueParser.String
instance GHC.Base.Applicative AesonValueParser.String
instance GHC.Base.Functor AesonValueParser.String
instance GHC.Base.Applicative AesonValueParser.Value
instance GHC.Base.Functor AesonValueParser.Value
instance Control.Monad.Fail.MonadFail AesonValueParser.Array
instance Control.Monad.Fail.MonadFail AesonValueParser.Object
instance GHC.Base.Alternative AesonValueParser.Value