Class: Hanami::Logger::JSONFormatter Private

Inherits:
Formatter
  • Object
show all
Defined in:
lib/hanami/logger/formatter.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Hanami::Logger JSON formatter. This formatter returns string in JSON format.

Since:

  • 0.5.0

Constant Summary

Constants inherited from Formatter

Formatter::NEW_LINE, Formatter::RESERVED_KEYS, Formatter::SEPARATOR

Instance Attribute Summary

Attributes inherited from Formatter

#application_name, #colorizer, #filter

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Formatter

#call, fabricate, inherited

Methods included from Utils::ClassAttribute

included

Class Method Details

.eligible?(name) ⇒ Boolean

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

Since:

  • 0.5.0



164
165
166
# File 'lib/hanami/logger/formatter.rb', line 164

def self.eligible?(name)
  name == :json
end

Instance Method Details

#colorizer=Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Since:

  • 0.5.0



169
170
171
# File 'lib/hanami/logger/formatter.rb', line 169

def colorizer=(*)
  @colorizer = NullColorizer.new
end