Class: Logging::Config::Configurator::TopLevelDSL
- Inherits:
-
DSL
- Object
- DSL
- Logging::Config::Configurator::TopLevelDSL
show all
- Defined in:
- lib/logging/config/configurator.rb
Instance Method Summary
collapse
Methods inherited from DSL
#__hash, #__store, #method_missing, process
Constructor Details
Returns a new instance of TopLevelDSL.
163
164
165
166
|
# File 'lib/logging/config/configurator.rb', line 163
def initialize
@loggers = []
@appenders = []
end
|
Instance Method Details
#__appenders ⇒ Object
182
|
# File 'lib/logging/config/configurator.rb', line 182
def __appenders() @appenders; end
|
#__loggers ⇒ Object
181
|
# File 'lib/logging/config/configurator.rb', line 181
def __loggers() @loggers; end
|
#__pre_config ⇒ Object
180
|
# File 'lib/logging/config/configurator.rb', line 180
def __pre_config() __hash[:preconfig]; end
|
#appender(name, &block) ⇒ Object
176
177
178
|
# File 'lib/logging/config/configurator.rb', line 176
def appender( name, &block )
@appenders << [name, DSL.process(&block)]
end
|
#logger(name, &block) ⇒ Object
172
173
174
|
# File 'lib/logging/config/configurator.rb', line 172
def logger( name, &block )
@loggers << [name, DSL.process(&block)]
end
|
#pre_config(&block) ⇒ Object
168
169
170
|
# File 'lib/logging/config/configurator.rb', line 168
def pre_config( &block )
__store(:preconfig, DSL.process(&block))
end
|