1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
|
module Network.HTTP.Types.Version
(
HttpVersion(..)
, http09
, http10
, http11
)
where
-- | HTTP Version.
--
-- Note that the Show instance is intended merely for debugging.
data HttpVersion
= HttpVersion {
httpMajor :: !Int
, httpMinor :: !Int
}
deriving (Eq, Ord)
instance Show HttpVersion where
show (HttpVersion major minor) = "HTTP/" ++ show major ++ "." ++ show minor
-- | HTTP 0.9
http09 :: HttpVersion
http09 = HttpVersion 0 9
-- | HTTP 1.0
http10 :: HttpVersion
http10 = HttpVersion 1 0
-- | HTTP 1.1
http11 :: HttpVersion
http11 = HttpVersion 1 1
|