Module: MrLogaLoga::InstanceMethods Private
- Defined in:
- lib/mr_loga_loga/instance_methods.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Description
Instance methods to be attached when including the main module.
Instance Method Summary collapse
- #loga_context ⇒ Object private
- #loga_loga ⇒ Object private
- #logger ⇒ Object private
Instance Method Details
#loga_context ⇒ 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.
10 11 12 |
# File 'lib/mr_loga_loga/instance_methods.rb', line 10 def loga_context { class_name: self.class.name } end |
#loga_loga ⇒ 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.
22 23 24 25 26 27 28 |
# File 'lib/mr_loga_loga/instance_methods.rb', line 22 def loga_loga @loga_loga ||= if defined?(Rails.logger) Rails.logger else MrLogaLoga.configuration.logger end end |
#logger ⇒ 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.
14 15 16 17 18 19 20 |
# File 'lib/mr_loga_loga/instance_methods.rb', line 14 def logger if loga_loga.is_a?(MrLogaLoga::Logger) MrLogaLoga::LoggerProxy.new(loga_loga, -> { loga_context }) else loga_loga end end |