Sha256: 5b65c28617d169a96b864e288bcb9700f312f6e301511cdde0d02f82f2ceedfd
Contents?: true
Size: 489 Bytes
Versions: 9
Compression:
Stored size: 489 Bytes
Contents
module UniformNotifier class CustomizedLogger < Base @logger = nil def self.active? @logger end def self.out_of_channel_notify( message ) return unless active? @logger.warn message end def self.setup(logdev) require 'logger' @logger = Logger.new( logdev ) def @logger.format_message( severity, timestamp, progname, msg ) "#{timestamp.strftime("%Y-%m-%d %H:%M:%S")}[#{severity}] #{msg}" end end end end
Version data entries
9 entries across 9 versions & 1 rubygems