Argo
type Value = Value Source #
type Array = Array Int Value Source #
type Pair = Pair String Value Source #
type Object = Array Int Pair Source #
pattern Null :: Value Source #
pattern Boolean :: Bool -> Value Source #
pattern Number :: Integer -> Integer -> Value Source #
pattern String :: Text -> Value Source #
pattern Array :: Array -> Value Source #
pattern Object :: Object -> Value Source #
pattern Pair :: Text -> Value -> Pair Source #
encode :: ToValue a => a -> Builder Source #
decode :: FromValue a => ByteString -> Maybe a Source #
class FromValue a where Source #
Methods
fromValue :: Value -> Maybe a Source #
Defined in Argo.Class.FromValue
fromValue :: Value -> Maybe Bool Source #
fromValue :: Value -> Maybe Integer Source #
fromValue :: Value -> Maybe Text Source #
fromValue :: Value -> Maybe Value Source #
fromValue :: Value -> Maybe (Array Int a) Source #
fromValue :: Value -> Maybe (Array Int (Pair String a)) Source #
class ToValue a where Source #
toValue :: a -> Value Source #
Defined in Argo.Class.ToValue
toValue :: Bool -> Value Source #
toValue :: Integer -> Value Source #
toValue :: Text -> Value Source #
toValue :: Value -> Value Source #
toValue :: Array Int a -> Value Source #
toValue :: Array Int (Pair String a) -> Value Source #