Class: Sendxmpp::Log
- Inherits:
-
Logger
- Object
- Logger
- Sendxmpp::Log
- Includes:
- Config
- Defined in:
- lib/sendxmpp/log.rb
Instance Attribute Summary collapse
-
#logger_ins ⇒ Object
Returns the value of attribute logger_ins.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ Log
constructor
A new instance of Log.
Methods included from Config
Constructor Details
#initialize ⇒ Log
Returns a new instance of Log.
11 12 13 14 15 16 17 18 |
# File 'lib/sendxmpp/log.rb', line 11 def initialize if config.logfile super(config.logfile) else super(STDOUT) end self.level = (config.loglevel.nil?) ? WARN : config.loglevel.to_i end |
Instance Attribute Details
#logger_ins ⇒ Object
Returns the value of attribute logger_ins.
5 6 7 |
# File 'lib/sendxmpp/log.rb', line 5 def logger_ins @logger_ins end |
Class Method Details
.logger ⇒ Object
7 8 9 |
# File 'lib/sendxmpp/log.rb', line 7 def self.logger @logger ||= self.new end |