Class: Kangaru::Configurator
- Inherits:
-
Object
- Object
- Kangaru::Configurator
- Includes:
- Attributable, Validatable
- Defined in:
- lib/kangaru/configurator.rb
Direct Known Subclasses
Kangaru::Configurators::DatabaseConfigurator, Kangaru::Configurators::RequestConfigurator
Class Method Summary collapse
Instance Method Summary collapse
Methods included from Validatable
Methods included from Concern
#append_features, #class_methods, #included
Methods included from Attributable
Class Method Details
.key ⇒ Object
8 9 10 11 12 13 |
# File 'lib/kangaru/configurator.rb', line 8 def self.key to_s.gsub(/^.*::(?!.*::)/, "") .delete_suffix("Configurator") .to_snakecase .to_sym end |
Instance Method Details
#serialise ⇒ Object
15 16 17 18 19 |
# File 'lib/kangaru/configurator.rb', line 15 def serialise self.class.attributes.to_h do |setting| [setting, send(setting)] end.compact end |