Module: Bitcoin::Logger
- Defined in:
- lib/bitcoin/logger.rb
Defined Under Namespace
Classes: Logger
Class Method Summary (collapse)
Class Method Details
+ (Object) create(name)
27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/bitcoin/logger.rb', line 27 def self.create name if defined?(Log4r) @log = Log4r::Logger.new(name.to_s) @log.level = 0 @log.outputters << Log4r::Outputter.stdout @log.outputters << Log4r::FileOutputter.new("fout", :filename => "log/#{name}.log") else @log = Bitcoin::Logger::Logger.new(name) end @log end |