abstract struct Crylog::Handlers::AbstractLogHandler

Overview

Implements severity and bubble functionality.

Direct Known Subclasses

Defined in:

handlers/abstract_handler.cr

Constructors

Instance Method Summary

Instance methods inherited from struct Crylog::Handlers::LogHandler

close close

Constructor methods inherited from struct Crylog::Handlers::LogHandler

new new

Constructor Detail

def self.new(severity : Crylog::Severity = Crylog::Severity::Debug, bubble : Bool = true) #

Initializes a log handler that will handle any message with a severity greater than or equal to severity.

bubble determines if messages should continue on to the next handler.


[View source]

Instance Method Detail

def bubble : Bool #

Whether the message should be handled by the next handler.


[View source]
def bubble=(bubble : Bool) #

Whether the message should be handled by the next handler.


[View source]
def handles?(message : Crylog::Message) : Bool #

Determines if this handler is able to handle message.


[View source]
def severity : Crylog::Severity #

The minimum severity that this handler should handle.


[View source]
def severity=(severity : Crylog::Severity) #

The minimum severity that this handler should handle.


[View source]