Class: Resqued::Config::Base
- Inherits:
-
Object
- Object
- Resqued::Config::Base
- Includes:
- Dsl
- Defined in:
- lib/resqued/config/base.rb
Overview
Base class for config handlers.
Direct Known Subclasses
Instance Method Summary collapse
-
#apply(str, filename = "INLINE") ⇒ Object
Public: Apply the configuration in ‘str`.
-
#apply_all(configs) ⇒ Object
Public: Apply the configuration from several files.
Methods included from Dsl
#after_fork, #before_fork, #queue, #worker, #worker_factory, #worker_pool
Instance Method Details
#apply(str, filename = "INLINE") ⇒ Object
Public: Apply the configuration in ‘str`.
Currently, this is a simple wrapper around ‘instance_eval`.
13 14 15 16 |
# File 'lib/resqued/config/base.rb', line 13 def apply(str, filename = "INLINE") instance_eval(str, filename) results end |
#apply_all(configs) ⇒ Object
Public: Apply the configuration from several files.
19 20 21 22 23 24 25 26 |
# File 'lib/resqued/config/base.rb', line 19 def apply_all(configs) configs.each do |config| with_current_path(config[:path]) do instance_eval(config[:content], config[:path]) end end results end |