Logger.log

Logs a message.

  1. void log(LogMessage msg)
  2. void log(Level level, string msg, Exception exception, string moduleName, string functionName, string fileName, size_t lineNumber)
    struct Logger
    void
    log
    (,
    string msg
    ,
    Exception exception = null
    ,
    string moduleName = __MODULE__
    ,
    string functionName = __PRETTY_FUNCTION__
    ,
    string fileName = __FILE__
    ,
    size_t lineNumber = __LINE__
    )
  3. void log(Level level, Exception exception, string moduleName, string functionName, string fileName, size_t lineNumber)

Parameters

level Level

The log level.

msg string

The string message to log.

exception Exception

The exception that prompted this log. This may be null.

moduleName string

The name of the module. This will resolve to the current module name by default.

functionName string

The name of the function. This will resolve to the current function name by default.

fileName string

The name of the source file. This will resolve to the current source file by default.

lineNumber size_t

The line number in the source file. This will resolve to the current source file's line number by default.