Safe Haskell | None |
---|---|
Language | Haskell2010 |
This is the main module of heavy-logger
package. You usually need to import only this module.
All generally required modules are re-exported.
For simple usage cases, you may also want to import System.Log.Heavy.Shortcuts module.
Example of usage is:
import System.Log.Heavy import Data.Text.Format.Heavy ... withLogging backend id $ do liftIO $ putStr "Your name? " liftIO $ hFlush stdout name <- liftIO $ getLine logMessage $ infoMessage "name was {}" (Single name) liftIO $ putStrLn $ "Hello, " ++ name
See also Test.hs
.
- module System.Log.Heavy.Types
- module System.Log.Heavy.Backends
- withLogging :: MonadIO m => LogBackend -> (m a -> IO a) -> LoggingT m a -> m a
Reexports
module System.Log.Heavy.Types
module System.Log.Heavy.Backends
:: MonadIO m | |
=> LogBackend | Logging backend settings |
-> (m a -> IO a) | Runner to run |
-> LoggingT m a | Actions within |
-> m a |
Run LoggingT monad within some kind of IO monad.