Class: Miniatura::Logger

Inherits:
Object
  • Object
show all
Defined in:
lib/miniatura/logger.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ Logger

Returns a new instance of Logger.



5
6
7
8
9
10
11
12
# File 'lib/miniatura/logger.rb', line 5

def initialize options
  if options.has_key? :logger
    @logger = options[:logger]
  else
    @logger = Logger.new(STDOUT)
    @logger.level = Logger::INFO
  end
end

Instance Attribute Details

#loggerObject (readonly)

Returns the value of attribute logger.



3
4
5
# File 'lib/miniatura/logger.rb', line 3

def logger
  @logger
end