-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | a Haskell Webserver Interface
--
-- Hack: a Haskell Webserver Interface
--
--
-- - 02.06 added FlexibleInstances to fix an error under ghc
-- >=7.2
--
@package hack
@version 2012.2.6
module Hack
type Application = Env -> IO Response
type Middleware = Application -> Application
data RequestMethod
OPTIONS :: RequestMethod
GET :: RequestMethod
HEAD :: RequestMethod
POST :: RequestMethod
PUT :: RequestMethod
DELETE :: RequestMethod
TRACE :: RequestMethod
CONNECT :: RequestMethod
data Hack_UrlScheme
HTTP :: Hack_UrlScheme
HTTPS :: Hack_UrlScheme
type HackErrors = String -> IO ()
data Env
Env :: RequestMethod -> String -> String -> String -> String -> Int -> [(String, String)] -> [Int] -> Hack_UrlScheme -> ByteString -> HackErrors -> [(String, String)] -> [(ByteString, ByteString)] -> String -> Env
requestMethod :: Env -> RequestMethod
scriptName :: Env -> String
pathInfo :: Env -> String
queryString :: Env -> String
serverName :: Env -> String
serverPort :: Env -> Int
http :: Env -> [(String, String)]
hackVersion :: Env -> [Int]
hackUrlScheme :: Env -> Hack_UrlScheme
hackInput :: Env -> ByteString
hackErrors :: Env -> HackErrors
hackHeaders :: Env -> [(String, String)]
hackCache :: Env -> [(ByteString, ByteString)]
remoteHost :: Env -> String
data Response
Response :: Int -> [(String, String)] -> ByteString -> Response
status :: Response -> Int
headers :: Response -> [(String, String)]
body :: Response -> ByteString
instance Show RequestMethod
instance Read RequestMethod
instance Eq RequestMethod
instance Show Hack_UrlScheme
instance Eq Hack_UrlScheme
instance Show Env
instance Show Response
instance Default Env
instance Default Response
instance Default Hack_UrlScheme
instance Default RequestMethod
instance Show HackErrors