Class: RSwim::Logger::LeFormatter
- Inherits:
-
Logger::Formatter
- Object
- Logger::Formatter
- RSwim::Logger::LeFormatter
- Defined in:
- lib/rswim/logger.rb
Instance Method Summary collapse
- #call(severity, timestamp, progname, msg) ⇒ Object
-
#initialize(klass) ⇒ LeFormatter
constructor
A new instance of LeFormatter.
Constructor Details
#initialize(klass) ⇒ LeFormatter
Returns a new instance of LeFormatter.
20 21 22 23 |
# File 'lib/rswim/logger.rb', line 20 def initialize(klass) super() @klass = klass end |
Instance Method Details
#call(severity, timestamp, progname, msg) ⇒ Object
25 26 27 28 |
# File 'lib/rswim/logger.rb', line 25 def call(severity, , progname, msg) m = String === msg ? msg : msg.inspect "#{} | #{severity} | #{@klass} | #{m}\n" end |