Module: LLT::Helpers::Configuration
- Defined in:
- lib/llt/helpers/configuration.rb
Overview
currently not used, implemented slightly differently in LLT::Service class
Defined Under Namespace
Modules: ClassMethods
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.included(obj) ⇒ Object
5 6 7 |
# File 'lib/llt/helpers/configuration.rb', line 5 def self.included(obj) obj.extend(ClassMethods) end |
Instance Method Details
#configuration ⇒ Object
19 20 21 |
# File 'lib/llt/helpers/configuration.rb', line 19 def configuration self.class.configuration end |
#configure(options = {}) ⇒ Object
9 10 11 12 13 14 15 16 17 |
# File 'lib/llt/helpers/configuration.rb', line 9 def configure( = {}) # It might appeal here to refactor this to us merge. # Don't do it: we don't want everything that might be present in options, # only what we use in the configuration. Cf. specs. configuration.each do |key, (val, _)| val = [key] || val instance_variable_set("@#{key}", val) end end |