-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | This library contains functions for encoding <a>bytestring
--   builders</a> for <a>chunked HTTP/1.1 transfer</a>.
--   
--   This functionality was extracted from the <a>blaze-builder</a>
--   package.
@package bsb-http-chunked
@version 0.0.0.4


-- | HTTP/1.1 chunked transfer encoding as defined in <a>RFC 7230 Section
--   4.1</a>
module Data.ByteString.Builder.HTTP.Chunked

-- | Transform a builder such that it uses chunked HTTP transfer encoding.
--   
--   <pre>
--   &gt;&gt;&gt; :set -XOverloadedStrings
--   
--   &gt;&gt;&gt; import Data.ByteString.Builder as B
--   
--   &gt;&gt;&gt; let f = B.toLazyByteString . chunkedTransferEncoding . B.lazyByteString
--   
--   &gt;&gt;&gt; f "data"
--   "004\r\ndata\r\n"
--   </pre>
--   
--   <pre>
--   &gt;&gt;&gt; f ""
--   ""
--   </pre>
--   
--   <i>Note</i>: While for many inputs, the bytestring chunks that can be
--   obtained from the output via <tt><a>toChunks</a> .
--   <a>toLazyByteString</a></tt> each form a chunk in the sense of <a>RFC
--   7230 Section 4.1</a>, this correspondence doesn't hold in general.
chunkedTransferEncoding :: Builder -> Builder

-- | The zero-length chunk <tt>0\r\n\r\n</tt> signalling the termination of
--   the data transfer.
chunkedTransferTerminator :: Builder
