Class: Zold::Node::WebrickLog

Inherits:
Object
  • Object
show all
Defined in:
lib/zold/commands/node.rb

Overview

Fake logging facility for Webrick

Instance Method Summary collapse

Constructor Details

#initialize(log) ⇒ WebrickLog

Returns a new instance of WebrickLog.



381
382
383
# File 'lib/zold/commands/node.rb', line 381

def initialize(log)
  @log = log
end

Instance Method Details

#debug(msg) ⇒ Object



389
390
391
# File 'lib/zold/commands/node.rb', line 389

def debug(msg)
  # nothing
end

#debug?Boolean

Returns:

  • (Boolean)


401
402
403
# File 'lib/zold/commands/node.rb', line 401

def debug?
  @log.info?
end

#error(msg) ⇒ Object



393
394
395
# File 'lib/zold/commands/node.rb', line 393

def error(msg)
  @log.error('WEBRICK ' + msg)
end

#fatal(msg) ⇒ Object



397
398
399
# File 'lib/zold/commands/node.rb', line 397

def fatal(msg)
  @log.error('WEBRICK ' + msg)
end

#info(msg) ⇒ Object



385
386
387
# File 'lib/zold/commands/node.rb', line 385

def info(msg)
  @log.debug('WEBRICK ' + msg)
end