free-http-0.1.0.2: An HTTP Client based on Free Monads.

Safe HaskellNone
LanguageHaskell2010

Network.HTTP.Client.Free.PureClient

Description

A pure interepreter

Synopsis

Documentation

runHttp Source

Arguments

:: Monad m 
=> ignore

a parameter that will be ignored. It is included so client's can hot-swap interpreters (many will require a Manager type)

-> (RequestType client -> ResponseType client) 
-> FT (HttpF client) m a 
-> m a 

A pure interpreter based on a client-supplied mocking function

runTHttp Source

Arguments

:: (Monad m, MonadTrans t, Monad (t m)) 
=> ignore

a paramter that will be ignored. It is included so client's can host-swap interpreters (many will require a Manager type)

-> (RequestType client -> ResponseType client) 
-> FT (HttpF client) m a 
-> t m a 

A pure interpreter based on a client-supplied mocking function. The under- lying monad is `t m`, so computations will be lifted into `t m`.