http-link-header-1.0.1: A parser and writer for the HTTP Link header as specified in RFC 5988 "Web Linking".

Safe HaskellSafe
LanguageHaskell2010

Network.HTTP.Link.Parser

Description

The parser for the HTTP Link header as defined in RFC 5988. More liberal than the RFC though: does not validate URLs and other deep stuff, accepts whitespace in weird places.

Synopsis

Documentation

linkHeader :: Parser [Link] Source

The Attoparsec parser for the Link header.

parseLinkHeader' :: Text -> Either String [Link] Source

Parses a Link header, returns an Either, where Left is the Attoparsec error string (probably not a useful one).

parseLinkHeader :: Text -> Maybe [Link] Source

Parses a Link header, returns a Maybe.

parseLinkHeaderBS' :: ByteString -> Either String [Link] Source

Parses a Link header, returns an Either, where Left is the Attoparsec error string (probably not a useful one).

parseLinkHeaderBS :: ByteString -> Maybe [Link] Source

Parses a Link header, returns a Maybe.