abstract struct ColorLogging::ColorFormatter

Overview

Most of this class is directly cribbed from Crystal's own StaticFormatter class. Macro providing the colorizing option and the static with_colors method provided by this project. Modify the #run method below to change how log lines behave in terminal

Extended Modules

Direct Known Subclasses

Defined in:

cr-color-logging.cr

Constructors

Class Method Summary

Instance Method Summary

Macro Summary

Constructor Detail

def self.new(entry : Log::Entry, io : IO) #

[View source]

Class Method Detail

def self.format(entry, io) : Nil #

[View source]
def self.with_color(prop : String, color : Symbol) #

[View source]
def self.with_colored_severity(severity : Log::Severity, color : Symbol) #

[View source]

Instance Method Detail

abstract def run #

[View source]
def string(value : String) #

[View source]

Macro Detail

macro define_colorized_method(name, method_override = nil, conditional = nil) #

[View source]