Module
Foreign.Generic.Class
- Package
- purescript-foreign-generic
- Repository
- paf31/purescript-foreign-generic
#GenericDecode Source
class GenericDecode a where
Members
decodeOpts :: Options -> Foreign -> F a
Instances
GenericDecode NoConstructors
(IsSymbol name, GenericDecodeArgs rep, GenericCountArgs rep) => GenericDecode (Constructor name rep)
(GenericDecode a, GenericDecode b) => GenericDecode (Sum a b)
#GenericEncode Source
class GenericEncode a where
Members
encodeOpts :: Options -> a -> Foreign
Instances
GenericEncode NoConstructors
(IsSymbol name, GenericEncodeArgs rep) => GenericEncode (Constructor name rep)
(GenericEncode a, GenericEncode b) => GenericEncode (Sum a b)
#GenericDecodeArgs Source
class GenericDecodeArgs a where
Members
decodeArgs :: Options -> Int -> List Foreign -> F { next :: Int, rest :: List Foreign, result :: a }
Instances
GenericDecodeArgs NoArguments
(Decode_ a) => GenericDecodeArgs (Argument a)
(GenericDecodeArgs a, GenericDecodeArgs b) => GenericDecodeArgs (Product a b)
#GenericEncodeArgs Source
class GenericEncodeArgs a where
Members
encodeArgs :: Options -> a -> List Foreign
Instances
GenericEncodeArgs NoArguments
(Encode_ a) => GenericEncodeArgs (Argument a)
(GenericEncodeArgs a, GenericEncodeArgs b) => GenericEncodeArgs (Product a b)
#GenericCountArgs Source
#DecodeRecord Source
class DecodeRecord r rl | rl -> r where
Members
Instances
DecodeRecord () Nil
(Cons l a r_ r, DecodeRecord r_ rl_, IsSymbol l, Decode_ a, Lacks l r_) => DecodeRecord r (Cons l a rl_)
#EncodeRecord Source
class EncodeRecord r rl | rl -> r where
Members
Instances
EncodeRecord () Nil
(Cons l a r_ r, EncodeRecord r_ rl_, IsSymbol l, Encode_ a) => EncodeRecord r (Cons l a rl_)