Class: RelatonBib::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/relaton_bib/config.rb

Constant Summary collapse

PROGNAME =
"relaton-bib".freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



17
18
19
20
21
22
23
24
# File 'lib/relaton_bib/config.rb', line 17

def initialize
  @logger = ::Logger.new $stderr
  @logger.level = ::Logger::WARN
  @logger.progname = self.class::PROGNAME
  @logger.formatter = proc do |_severity, _datetime, progname, msg|
    "[#{progname}] #{msg}\n"
  end
end

Instance Attribute Details

#loggerObject

Returns the value of attribute logger.



15
16
17
# File 'lib/relaton_bib/config.rb', line 15

def logger
  @logger
end