Copyright | (c) 2018-2020 Kowainik |
---|---|
License | MPL-2.0 |
Maintainer | Kowainik <xrom.xkov@gmail.com> |
Safe Haskell | None |
Language | Haskell2010 |
Logging actions for various text types.
Synopsis
- logByteStringStdout :: MonadIO m => LogAction m ByteString
- logByteStringStderr :: MonadIO m => LogAction m ByteString
- logByteStringHandle :: MonadIO m => Handle -> LogAction m ByteString
- withLogByteStringFile :: MonadIO m => FilePath -> (LogAction m ByteString -> IO r) -> IO r
- logTextStdout :: MonadIO m => LogAction m Text
- logTextStderr :: MonadIO m => LogAction m Text
- logTextHandle :: MonadIO m => Handle -> LogAction m Text
- withLogTextFile :: MonadIO m => FilePath -> (LogAction m Text -> IO r) -> IO r
- simpleMessageAction :: MonadIO m => LogAction m Message
- richMessageAction :: MonadIO m => LogAction m Message
ByteString
actions
logByteStringStdout :: MonadIO m => LogAction m ByteString Source #
Action that prints ByteString
to stdout.
logByteStringStderr :: MonadIO m => LogAction m ByteString Source #
Action that prints ByteString
to stderr.
logByteStringHandle :: MonadIO m => Handle -> LogAction m ByteString Source #
Action that prints ByteString
to Handle
.
withLogByteStringFile :: MonadIO m => FilePath -> (LogAction m ByteString -> IO r) -> IO r Source #
Action that prints ByteString
to file. See
withLogStringFile
for details.
Text
actions
withLogTextFile :: MonadIO m => FilePath -> (LogAction m Text -> IO r) -> IO r Source #
Action that prints Text
to file. See
withLogStringFile
for details.
Message
actions
Default logging actions to make the usage with Message
s easier.
simpleMessageAction :: MonadIO m => LogAction m Message Source #
Action that prints Message
to stdout
.
richMessageAction :: MonadIO m => LogAction m Message Source #
Action that constructs RichMessage
and prints formatted
Message
for it to stdout
.