Class: Ductr::Log::ColorFormatter
- Inherits:
-
Logger::Formatter
- Object
- Logger::Formatter
- Ductr::Log::ColorFormatter
- Defined in:
- lib/ductr/log/formatters/color_formatter.rb
Overview
A log formatter which colorize the text with ANSI colors.
Instance Method Summary collapse
-
#call(level, time, prog_name, message) ⇒ String
Colorizes the given log entry.
Instance Method Details
#call(level, time, prog_name, message) ⇒ String
Colorizes the given log entry.
22 23 24 |
# File 'lib/ductr/log/formatters/color_formatter.rb', line 22 def call(level, time, prog_name, ) format(format_str(level), level[0], format_datetime(time), Process.pid, level, prog_name, msg2str()) end |