Class: Patriot::Util::Logger::Facade
- Inherits:
-
Object
- Object
- Patriot::Util::Logger::Facade
- Defined in:
- lib/patriot/util/logger/facade.rb
Overview
facade class for loggers
Constant Summary collapse
- LEVELS =
supported log levels
[:debug, :info, :warn, :error, :fatal]
Instance Method Summary collapse
-
#initialize(logger) ⇒ Facade
constructor
A new instance of Facade.
-
#write(msg) ⇒ Object
for Rack::CommonLogger.
Constructor Details
#initialize(logger) ⇒ Facade
Returns a new instance of Facade.
10 11 12 |
# File 'lib/patriot/util/logger/facade.rb', line 10 def initialize(logger) @logger = logger end |
Instance Method Details
#write(msg) ⇒ Object
for Rack::CommonLogger
26 27 28 |
# File 'lib/patriot/util/logger/facade.rb', line 26 def write(msg) @logger.info(msg) end |