Class: Fluent::Logger::LoggerBase

Inherits:
Object
  • Object
show all
Defined in:
lib/fluent/logger/logger_base.rb

Direct Known Subclasses

FluentLogger, NullLogger, TestLogger, TextLogger

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.open(*args, &block) ⇒ Object



21
22
23
# File 'lib/fluent/logger/logger_base.rb', line 21

def self.open(*args, &block)
  Fluent::Logger.open(self, *args, &block)
end

Instance Method Details

#closeObject

def post_with_time(tag, map) end



33
34
# File 'lib/fluent/logger/logger_base.rb', line 33

def close
end

#post(tag, map) ⇒ Object

Raises:

  • (ArgumentError)


25
26
27
28
# File 'lib/fluent/logger/logger_base.rb', line 25

def post(tag, map)
  raise ArgumentError.new("Second argument must be a kind of Hash (#{tag}: #{map})") unless map.kind_of? Hash
  post_with_time(tag, map, Time.now)
end