struct Earl::Logger::Log

Defined in:

logger.cr

Instance Method Summary

Instance Method Detail

def debug(message : String) : Nil #

Logs message if #debug? returns true.


[View source]
def debug(&block : -> String) : Nil #

Logs the message returned by the block if #debug? returns true, otherwise the block is never invoked.


[View source]
def debug? : Bool #

Returns true if the current level is DEBUG or lower.


[View source]
def error(message : String) : Nil #

Logs message if #error? returns true.


[View source]
def error(&block : -> String) : Nil #

Logs the message returned by the block if #error? returns true, otherwise the block is never invoked.


[View source]
def error(ex : Exception) #

[View source]
def error? : Bool #

Returns true if the current level is ERROR or lower.


[View source]
def info(message : String) : Nil #

Logs message if #info? returns true.


[View source]
def info(&block : -> String) : Nil #

Logs the message returned by the block if #info? returns true, otherwise the block is never invoked.


[View source]
def info? : Bool #

Returns true if the current level is INFO or lower.


[View source]
def silent? : Bool #

Returns true if the current level is SILENT.


[View source]
def warn(message : String) : Nil #

Logs message if #warn? returns true.


[View source]
def warn(&block : -> String) : Nil #

Logs the message returned by the block if #warn? returns true, otherwise the block is never invoked.


[View source]
def warn? : Bool #

Returns true if the current level is WARN or lower.


[View source]