ihttp-0.1.0: Incremental HTTP iteratee

Stabilityexperimental
MaintainerErtugrul Soeylemez <es@ertes.de>

Network.IHttp.Response

Contents

Description

Iteratees for response.

Synopsis

Iteratees

response :: Monad m => Int -> Int -> Iteratee ByteString m ResponseSource

Get the next full response from a netLinesEmpty-splitted byte stream. If the response is invalid or the stream ends prematurely an iteratee error is thrown. The first Int specifies the maximum header content length. The second Int specifies the maximum number of headers. Excess data is truncated safely in constant space.

responseLine :: Monad m => Iteratee ByteString m ResponseSource

Get the next response line form netLinesEmpty-splitted stream. If the response line is invalid or the stream ended prematurely, then an iteratee error is thrown.