Class: Rootage::NullLogger
Overview
NullLogger
is a logger that ignores all messages.
Instance Attribute Summary collapse
-
#level ⇒ Object
Returns the value of attribute level.
Instance Method Summary collapse
- #debug(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
- #error(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
- #fatal(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
- #info(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
-
#initialize ⇒ NullLogger
constructor
A new instance of NullLogger.
- #queued? ⇒ Boolean
- #terminate ⇒ Object
- #warn(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
Methods inherited from Logger
Constructor Details
#initialize ⇒ NullLogger
Returns a new instance of NullLogger.
113 114 115 |
# File 'lib/rootage/log.rb', line 113 def initialize @level = :info end |
Instance Attribute Details
#level ⇒ Object
Returns the value of attribute level.
111 112 113 |
# File 'lib/rootage/log.rb', line 111 def level @level end |
Instance Method Details
#debug(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
121 |
# File 'lib/rootage/log.rb', line 121 def debug(msg, pos=caller(1).first, pid=Process.pid); end |
#error(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
118 |
# File 'lib/rootage/log.rb', line 118 def error(msg, pos=caller(1).first, pid=Process.pid); end |
#fatal(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
117 |
# File 'lib/rootage/log.rb', line 117 def fatal(msg, pos=caller(1).first, pid=Process.pid); end |
#info(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
120 |
# File 'lib/rootage/log.rb', line 120 def info (msg, pos=caller(1).first, pid=Process.pid); end |
#queued? ⇒ Boolean
127 128 129 |
# File 'lib/rootage/log.rb', line 127 def queued? false end |
#terminate ⇒ Object
123 124 125 |
# File 'lib/rootage/log.rb', line 123 def terminate # ignore end |
#warn(msg, pos = caller(1).first, pid = Process.pid) ⇒ Object
119 |
# File 'lib/rootage/log.rb', line 119 def warn (msg, pos=caller(1).first, pid=Process.pid); end |