Module: ValueObject::DSL
- Included in:
- Base
- Defined in:
- lib/value_object/dsl.rb
Instance Attribute Summary collapse
-
#all ⇒ Object
Returns the value of attribute all.
Instance Method Summary collapse
Instance Attribute Details
#all ⇒ Object
Returns the value of attribute all.
9 10 11 |
# File 'lib/value_object/dsl.rb', line 9 def all @all end |
Instance Method Details
#find(key) ⇒ Object
3 4 5 6 7 |
# File 'lib/value_object/dsl.rb', line 3 def find(key) return unless key object = all.find { |v| v.key.to_s.eql?(key.to_s) } object || raise_invalid_value(key) end |