Rel8.Decoder
data Decoder a Source #
Constructors
Fields
How to deserialize from PostgreSQL's binary format.
How to deserialize from PostgreSQL's text format.
Defined in Rel8.Type.Decoder
Methods
fmap :: (a -> b) -> Decoder a -> Decoder b #
(<$) :: a -> Decoder b -> Decoder a #
type Parser a = ByteString -> Either String a Source #
parseDecoder :: (a -> Either String b) -> Decoder a -> Decoder b Source #
Apply a parser to Decoder.
Decoder
This can be used if the data stored in the database should only be subset of a given Decoder. The parser is applied when deserializing rows returned.