Class: SandiMeter::Logger

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#dataObject

Returns the value of attribute data

Returns:

  • (Object)

    the current value of data



4
5
6
# File 'lib/sandi_meter/logger.rb', line 4

def data
  @data
end

Instance Method Details

#log!(path) ⇒ Object



5
6
7
8
9
# File 'lib/sandi_meter/logger.rb', line 5

def log!(path)
  File.open(File.join(path, 'sandi_meter', 'sandi_meter.log'), 'a') do |file|
    file.puts(log_line)
  end
end