class Flor::Logger::Out

Attributes

unit[R]

Public Class Methods

new(unit) click to toggle source
# File lib/flor/unit/logger.rb, line 262
def initialize(unit); @unit = unit; end
prepare(unit) click to toggle source
# File lib/flor/unit/logger.rb, line 268
def self.prepare(unit)

  case o = unit.conf.fetch('log_out', 1)
  when false, 'null' then NoOut.new(unit)
  when 1, true, 'stdout' then StdOut.new(unit, $stdout)
  when 2, 'stderr' then StdOut.new(unit, $stderr)
  when /::/ then Flor.const_lookup(o).new(unit)
  else FileOut.new(unit, o)
  end
end

Public Instance Methods

close() click to toggle source
# File lib/flor/unit/logger.rb, line 266
def close; end
flush() click to toggle source
# File lib/flor/unit/logger.rb, line 265
def flush; end
log_colours?() click to toggle source
# File lib/flor/unit/logger.rb, line 263
def log_colours?; @unit.conf.fetch('log_colours') { :no } == true; end
puts(s) click to toggle source
# File lib/flor/unit/logger.rb, line 264
def puts(s); end