Class: Hippo::MultiDestinationLogger
- Inherits:
-
Logger
- Object
- Logger
- Hippo::MultiDestinationLogger
- Defined in:
- lib/hippo/logger.rb
Defined Under Namespace
Classes: Output
Instance Method Summary collapse
-
#initialize ⇒ MultiDestinationLogger
constructor
A new instance of MultiDestinationLogger.
Constructor Details
#initialize ⇒ MultiDestinationLogger
Returns a new instance of MultiDestinationLogger.
24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/hippo/logger.rb', line 24 def initialize super Output.new self.formatter = proc do |severity, datetime, progname, msg| sprintf "%5.5s %s\n", severity, msg end if ENV['LOG'] self.level = ::Logger.const_get(ENV['LOG'].upcase) else self.level = ::Logger::INFO end end |