http-server-1.0.6: A library for writing Haskell web servers.

Copyright(c) Galois, Inc. 2007, 2008
LicenseBSD3
Maintainerdiatchki@galois.com
Stabilityprovisional
Portability
Safe HaskellSafe-Inferred
LanguageHaskell98

Network.HTTP.Server.Logger

Description

 

Synopsis

Documentation

data Logger Source

A type used by the server to report various events. Useful for debugging.

Constructors

Logger 

Fields

logInfo :: Int -> String -> IO ()
 
logDebug :: String -> IO ()
 
logError :: String -> IO ()
 
logWarning :: String -> IO ()
 
getLog :: Maybe Int -> (LogType -> Bool) -> IO [LogItem]
 

stdLogger :: Logger Source

A logger that uses the standard output and standard error. Text is UTF8 encoded.

quietLogger :: Logger Source

A logger that does not report anything.

utf8Logger :: Handle -> Handle -> Logger Source

A logger that uses the given handles for output and errors.

data LogItem Source

Constructors

LogItem 

data LogType Source

Constructors

Error 
Warning 
Debug 
Info Int 

Instances