Class: HQ::Logger::MultiLogger

Inherits:
Object
  • Object
show all
Defined in:
lib/hq/logger/multi-logger.rb

Instance Method Summary collapse

Constructor Details

#initializeMultiLogger

Returns a new instance of MultiLogger.



6
7
8
# File 'lib/hq/logger/multi-logger.rb', line 6

def initialize
	@loggers = []
end

Instance Method Details

#add_logger(logger) ⇒ Object



10
11
12
# File 'lib/hq/logger/multi-logger.rb', line 10

def add_logger logger
	@loggers << logger
end

#output(content, stuff, prefix = "") ⇒ Object



14
15
16
17
18
19
# File 'lib/hq/logger/multi-logger.rb', line 14

def output content, stuff, prefix = ""
	@loggers.each do
		|logger|
		logger.output content, stuff, prefix
	end
end