Class: Log

Inherits:
Object
  • Object
show all
Defined in:
lib/yodel/models/core/log/log.rb

Instance Method Summary collapse

Constructor Details

#initialize(site) ⇒ Log

Returns a new instance of Log.



4
5
6
# File 'lib/yodel/models/core/log/log.rb', line 4

def initialize(site)
  @site = site
end

Instance Method Details

#debug(message) ⇒ Object



8
9
10
# File 'lib/yodel/models/core/log/log.rb', line 8

def debug(message)
  build_log_entry(LogEntry::DEBUG, message)
end

#error(message) ⇒ Object



20
21
22
# File 'lib/yodel/models/core/log/log.rb', line 20

def error(message)
  build_log_entry(LogEntry::ERROR, message)
end

#fatal(message) ⇒ Object



24
25
26
# File 'lib/yodel/models/core/log/log.rb', line 24

def fatal(message)
  build_log_entry(LogEntry::FATAL, message)
end

#info(message) ⇒ Object



12
13
14
# File 'lib/yodel/models/core/log/log.rb', line 12

def info(message)
  build_log_entry(LogEntry::INFO, message)
end

#warn(message) ⇒ Object



16
17
18
# File 'lib/yodel/models/core/log/log.rb', line 16

def warn(message)
  build_log_entry(LogEntry::WARN, message)
end