Class: MinatoLogger::Configuration
- Inherits:
-
Object
- Object
- MinatoLogger::Configuration
- Defined in:
- lib/minato_logger/configuration.rb
Instance Attribute Summary collapse
-
#middleware ⇒ Object
readonly
Returns the value of attribute middleware.
Class Method Summary collapse
Instance Method Summary collapse
- #configure {|_self| ... } ⇒ Object
-
#initialize {|_self| ... } ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize {|_self| ... } ⇒ Configuration
Returns a new instance of Configuration.
7 8 9 10 11 |
# File 'lib/minato_logger/configuration.rb', line 7 def initialize @middleware = MinatoLogger::Middleware.new yield(self) if block_given? end |
Instance Attribute Details
#middleware ⇒ Object (readonly)
Returns the value of attribute middleware.
5 6 7 |
# File 'lib/minato_logger/configuration.rb', line 5 def middleware @middleware end |
Class Method Details
.default ⇒ Object
13 14 15 |
# File 'lib/minato_logger/configuration.rb', line 13 def self.default @default ||= Configuration.new end |
Instance Method Details
#configure {|_self| ... } ⇒ Object
17 18 19 |
# File 'lib/minato_logger/configuration.rb', line 17 def configure yield(self) if block_given? end |