http-types-0.8.6: Generic HTTP types for Haskell (for both client and server code).

Safe Haskell | None
Language | Haskell98

Network.HTTP.Types.Header

Contents

- Types
- Common headers
- Byte ranges

Synopsis

- type Header = (HeaderName, ByteString)
- type HeaderName = CI ByteString
- type RequestHeaders = [Header]
- type ResponseHeaders = [Header]
- hAccept :: HeaderName
- hAcceptLanguage :: HeaderName
- hAuthorization :: HeaderName
- hCacheControl :: HeaderName
- hCookie :: HeaderName
- hConnection :: HeaderName
- hContentEncoding :: HeaderName
- hContentLength :: HeaderName
- hContentMD5 :: HeaderName
- hContentType :: HeaderName
- hDate :: HeaderName
- hIfModifiedSince :: HeaderName
- hIfRange :: HeaderName
- hLastModified :: HeaderName
- hLocation :: HeaderName
- hRange :: HeaderName
- hReferer :: HeaderName
- hServer :: HeaderName
- hUserAgent :: HeaderName
- data ByteRange
  - = ByteRangeFrom !Integer
  - | ByteRangeFromTo !Integer !Integer
  - | ByteRangeSuffix !Integer
- renderByteRangeBuilder :: ByteRange -> Builder
- renderByteRange :: ByteRange -> ByteString
- type ByteRanges = [ByteRange]
- renderByteRangesBuilder :: ByteRanges -> Builder
- renderByteRanges :: ByteRanges -> ByteString

## Types

type Header = (HeaderName, ByteString)

Header

type HeaderName = CI ByteString

Header name

type RequestHeaders = [Header]

Request Headers

type ResponseHeaders = [Header]

Response Headers

## Common headers

hAccept :: HeaderName

HTTP Header names

hAcceptLanguage :: HeaderName

HTTP Header names

hAuthorization :: HeaderName

HTTP Header names

hCacheControl :: HeaderName

HTTP Header names

hCookie :: HeaderName

HTTP Header names

hConnection :: HeaderName

HTTP Header names

hContentEncoding :: HeaderName

HTTP Header names

hContentLength :: HeaderName

HTTP Header names

hContentMD5 :: HeaderName

HTTP Header names

hContentType :: HeaderName

HTTP Header names

hDate :: HeaderName

HTTP Header names

hIfModifiedSince :: HeaderName

HTTP Header names

hIfRange :: HeaderName

HTTP Header names

hLastModified :: HeaderName

HTTP Header names

hLocation :: HeaderName

HTTP Header names

hRange :: HeaderName

HTTP Header names

hReferer :: HeaderName

HTTP Header names

hServer :: HeaderName

HTTP Header names

hUserAgent :: HeaderName

HTTP Header names

## Byte ranges

data ByteRange

RFC 2616 Byte range (individual).

Negative indices are not allowed!

Constructors

ByteRangeFrom !Integer |
ByteRangeFromTo !Integer !Integer |
ByteRangeSuffix !Integer |

Instances

Eq ByteRange |
Data ByteRange |
Ord ByteRange |
Show ByteRange |
Typeable * ByteRange |

renderByteRangeBuilder :: ByteRange -> Builder

renderByteRange :: ByteRange -> ByteString

type ByteRanges = [ByteRange]

RFC 2616 Byte ranges (set).

renderByteRangesBuilder :: ByteRanges -> Builder

renderByteRanges :: ByteRanges -> ByteString