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

-- | HTTP Date parser/formatter
--   
--   Fast parser and formatter for HTTP Date
@package http-date
@version 0.0.11

-- | Fast parser and formatter for HTTP Date.
module Network.HTTP.Date

-- | Translating EpochTime to HTTPDate.
epochTimeToHTTPDate :: EpochTime -> HTTPDate

-- | Translating HTTPDate to UTCTime.
--   
--   Since 0.0.7.
httpDateToUTC :: HTTPDate -> UTCTime

-- | Translating UTCTime to HTTPDate.
--   
--   Since 0.0.7.
utcToHTTPDate :: UTCTime -> HTTPDate

-- | Data structure for HTTP Date. This value should be specified with
--   defaultHTTPDate and its field labels.
data HTTPDate

-- | A default value for HTTPDate.
defaultHTTPDate :: HTTPDate

-- | Parsing HTTP Date. Currently only RFC1123 style is supported.
--   
--   
--   >>> parseHTTPDate "Tue, 15 Nov 1994 08:12:31 GMT"
--   Just (HTTPDate {hdYear = 1994, hdMonth = 11, hdDay = 15, hdHour = 8, hdMinute = 12, hdSecond = 31, hdWkday = 2})
--   
parseHTTPDate :: ByteString -> Maybe HTTPDate

-- | Generating HTTP Date in RFC1123 style.
--   
--   
--   >>> formatHTTPDate defaultHTTPDate {hdYear = 1994, hdMonth = 11, hdDay = 15, hdHour = 8, hdMinute = 12, hdSecond = 31, hdWkday = 2}
--   "Tue, 15 Nov 1994 08:12:31 GMT"
--   
formatHTTPDate :: HTTPDate -> ByteString
