linnet-0.4.0.1: Lightweight library for building HTTP API

Safe HaskellNone
LanguageHaskell2010

Linnet.Encode

Synopsis

Documentation

class Encode ct a Source #

Encoding of some type a into payload of HTTP response Phantom type ct guarantees that compiler checks support of encoding of some a into content of given Content-Type by looking for specific Encode instance.

Minimal complete definition

encode

Instances
Encode TextPlain Double Source # 
Instance details

Defined in Linnet.Encode

Encode TextPlain Float Source # 
Instance details

Defined in Linnet.Encode

Encode TextPlain Int Source # 
Instance details

Defined in Linnet.Encode

Encode TextPlain Integer Source # 
Instance details

Defined in Linnet.Encode

Encode TextPlain ByteString Source # 
Instance details

Defined in Linnet.Encode

Encode TextPlain ByteString Source # 
Instance details

Defined in Linnet.Encode

Encode TextPlain Text Source # 
Instance details

Defined in Linnet.Encode

Encode TextPlain Text Source # 
Instance details

Defined in Linnet.Encode

encode :: Encode ct a => a -> ByteString Source #