Class: TextRecord::YAMLAttribute
- Defined in:
- lib/text_record/attribute.rb
Instance Attribute Summary
Attributes inherited from Attribute
Instance Method Summary collapse
Methods inherited from Attribute
Constructor Details
This class inherits a constructor from TextRecord::Attribute
Instance Method Details
#parse(obj) ⇒ Object
16 17 18 |
# File 'lib/text_record/attribute.rb', line 16 def parse(obj) obj.instance_variable_set("@#{name.to_s.underscore}".to_sym, obj.yml[name.to_s.camelcase]) end |