Codec.Json.Unidirectional.Decode.Class
- Package
- purescript-json-codecs
- Repository
- jordanmartinez/purescript-json-codecs
#DecodeJson Source
class DecodeJson err extra a whereMembers
decodeJson :: JsonDecoder err extra a
Instances
DecodeJson err extra JsonDecodeJson err extra VoidDecodeJson err extra UnitDecodeJson err extra BooleanDecodeJson err extra IntDecodeJson err extra CharDecodeJson err extra NumberDecodeJson err extra StringDecodeJson err extra NonEmptyString(DecodeJson err extra a) => DecodeJson err extra (Array a)(DecodeJson err extra a) => DecodeJson err extra (NonEmptyArray a)(DecodeJson err extra a) => DecodeJson err extra (Object a)(DecodeJson err extra a) => DecodeJson err extra (Nullable a)(DecodeJson err extra a) => DecodeJson err extra (Identity a)(DecodeJson err extra a) => DecodeJson err extra (Maybe a)(DecodeJson err extra l, DecodeJson err extra r) => DecodeJson err extra (Either l r)(DecodeJson err extra l, DecodeJson err extra r) => DecodeJson err extra (Tuple l r)(DecodeJson err extra l, DecodeJson err extra r) => DecodeJson err extra (These l r)(DecodeJson err extra a, DecodeJson err extra (f a)) => DecodeJson err extra (NonEmpty f a)(DecodeJson err extra a) => DecodeJson err extra (List a)(DecodeJson err extra a) => DecodeJson err extra (NonEmptyList a)(Ord k, DecodeJson err extra k, DecodeJson err extra v) => DecodeJson err extra (Map k v)(Ord a, DecodeJson err extra a) => DecodeJson err extra (Set a)(Ord a, DecodeJson err extra a) => DecodeJson err extra (NonEmptySet a)DecodeJson err extra CodePoint(Newtype extra (Record rows), Cons sym (ExistentialDecoder0 a) tail rows, IsSymbol sym) => DecodeJson err extra (K0 sym a)(Newtype extra (Record rows), Cons sym (ExistentialDecoder1 f) tail rows, DecodeJson err extra a, IsSymbol sym) => DecodeJson err extra (K1 sym (f a))Local overrides for types with kind
Type. Implementation for types annotated with theK1type are provided via theextralabel inJsonDecoderInput. Value forextramust be a newtyped record. ThesyminK1 sym amust be the label name witin that newtyped record that contains the function,JsonDecoder err extra a -> JsonDecoder err extra (f a). The input argument is the correspondingDecodeJsonimplementation fora. Thus, one is only overriding the implementation forf, notaas well.(Newtype extra (Record rows), Cons sym (ExistentialDecoder2 f) tail rows, DecodeJson err extra a, DecodeJson err extra b, IsSymbol sym) => DecodeJson err extra (K2 sym (f a b))Local overrides for types with kind
Type. Implementation for types annotated with theK2type are provided via theextralabel inJsonDecoderInput. Value forextramust be a newtyped record. ThesyminK2 sym amust be the label name witin that newtyped record that contains the function,JsonDecoder err extra a -> JsonDecoder err extra b -> JsonDecoder err extra (f a b). The input arguments are the correspondingDecodeJsonimplementations foraandb. Thus, one is only overriding the implementation forf, notaandbas well.(Newtype extra (Record rows), Cons sym (ExistentialDecoder3 f) tail rows, DecodeJson err extra a, DecodeJson err extra b, DecodeJson err extra c, IsSymbol sym) => DecodeJson err extra (K3 sym (f a b c))Local overrides for types with kind
Type. Implementation for types annotated with theK3type are provided via theextralabel inJsonDecoderInput. Value forextramust be a newtyped record. ThesyminK3 sym amust be the label name witin that newtyped record that contains the function,JsonDecoder err extra a -> JsonDecoder err extra b -> JsonDecoder err extra c -> JsonDecoder err extra (f a b c). The input arguments are the correspondingDecodeJsonimplementations fora,b, andc. Thus, one is only overriding the implementation forf, nota,b, andcas well.(RowToList rows rl, BuildPropDecoders err extra rl rows) => DecodeJson err extra (Record rows)DecodeJson e extra NoArguments(DecodeJson e extra a, DecodeJson e extra b) => DecodeJson e extra (Sum a b)(DecodeJson e extra a, DecodeJson e extra b) => DecodeJson e extra (Product a b)(DecodeJson e extra a, IsSymbol sym) => DecodeJson e extra (Constructor sym a)(DecodeJson e extra a, IsSymbol sym) => DecodeJson e extra (Argument a)
#ExistentialDecoder0 Source
data ExistentialDecoder0 t0Build a value via mkExistentialDecoder0.
#mkExistentialDecoder0 Source
mkExistentialDecoder0 :: forall err extra a. JsonDecoder err extra a -> ExistentialDecoder0 a#ExistentialDecoder1 Source
data ExistentialDecoder1 :: (Type -> Type) -> Typedata ExistentialDecoder1 t0
Build a value via mkExistentialDecoder1.
#mkExistentialDecoder1 Source
mkExistentialDecoder1 :: forall err extra f a. (JsonDecoder err extra a -> JsonDecoder err extra (f a)) -> ExistentialDecoder1 f#ExistentialDecoder2 Source
data ExistentialDecoder2 :: (Type -> Type -> Type) -> Typedata ExistentialDecoder2 t0
Build a value via mkExistentialDecoder2.
#mkExistentialDecoder2 Source
mkExistentialDecoder2 :: forall err extra f a b. (JsonDecoder err extra a -> JsonDecoder err extra b -> JsonDecoder err extra (f a b)) -> ExistentialDecoder2 f#ExistentialDecoder3 Source
data ExistentialDecoder3 :: (Type -> Type -> Type -> Type) -> Typedata ExistentialDecoder3 t0
Build a value via mkExistentialDecoder3.
#mkExistentialDecoder3 Source
mkExistentialDecoder3 :: forall err extra f a b c. (JsonDecoder err extra a -> JsonDecoder err extra b -> JsonDecoder err extra c -> JsonDecoder err extra (f a b c)) -> ExistentialDecoder3 f#RowListJsonObjDecoder Source
newtype RowListJsonObjDecoder :: Type -> Type -> RowList Type -> Row Type -> Typenewtype RowListJsonObjDecoder err extra rl rows
#BuildPropDecoders Source
class BuildPropDecoders :: Type -> Type -> RowList Type -> Row Type -> Constraintclass BuildPropDecoders err extra rl out | err extra rl -> out where
Members
buildPropDecoders :: RowListJsonObjDecoder err extra rl out
Instances
BuildPropDecoders err extra Nil ()(DecodeJson err extra a, BuildPropDecoders err extra tailList intermediate, Lacks sym intermediate, Cons sym (Optional (Maybe a)) intermediate out, IsSymbol sym) => BuildPropDecoders err extra (Cons sym (Optional (Maybe a)) tailList) out(DecodeJson err extra a, BuildPropDecoders err extra tailList intermediate, Lacks sym intermediate, Cons sym a intermediate out, IsSymbol sym) => BuildPropDecoders err extra (Cons sym a tailList) out
#VCTypeHint Source
class VCTypeHint :: Type -> Type -> RowList Type -> Row Type -> Type -> Constraintclass VCTypeHint e extra rl row a | e extra rl a -> row where
Members
vcTypeHint :: VCHint e extra rl row a -> (JsonDecoder' e extra (Object Json) (Variant row) -> JsonDecoder' e extra (Object Json) (Variant row))
Instances
(IsSymbol sym) => VCTypeHint e extra rl row (WithType sym a)(IsSymbol sym) => VCTypeHint e extra rl row (WithCtor sym a)(Reflectable int Int) => VCTypeHint e extra rl row (WithSubterm int a)(IsSymbol sym) => VCTypeHint e extra rl row (WithField sym a)(IsSymbol sym) => VCTypeHint e extra rl row a
- Modules
- Codec.
Codec - Codec.
Decoder - Codec.
Decoder. Qualified - Codec.
Json. Bidirectional. Class - Codec.
Json. Bidirectional. Value - Codec.
Json. Errors. AnsiDodoError - Codec.
Json. Errors. DecodeMessages - Codec.
Json. Errors. NoError - Codec.
Json. Errors. PlainDodoError - Codec.
Json. Errors. PrimitiveJsonError - Codec.
Json. Errors. Tree - Codec.
Json. JsonCodec - Codec.
Json. JsonDecoder - Codec.
Json. Newtypes - Codec.
Json. Types - Codec.
Json. Unidirectional. Decode. Class - Codec.
Json. Unidirectional. Decode. Value - Codec.
Json. Unidirectional. Encode. Class - Codec.
Json. Unidirectional. Encode. Value - Data.
V. Semigroup. Qualified
Local overrides for types with kind
Type. Implementation for types annotated with theK0type are provided via theextralabel inJsonDecoderInput. Value forextramust be a newtyped record. ThesyminK0 sym amust be the label name witin that newtyped record that contains the local override (i.e.JsonDecoder err extra a).