Module: Yaoc::Strategies::ToHashMapping
- Defined in:
- lib/yaoc/strategies/to_hash_mapping.rb
Defined Under Namespace
Modules: ClassMethods
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.included(other) ⇒ Object
4 5 6 |
# File 'lib/yaoc/strategies/to_hash_mapping.rb', line 4 def self.included(other) other.extend(ClassMethods) end |
Instance Method Details
#call ⇒ Object
8 9 10 11 12 |
# File 'lib/yaoc/strategies/to_hash_mapping.rb', line 8 def call converter_methods.reduce({}) do |result, method_name| self.public_send(method_name, to_convert, result) end end |