Module: Ripple::Associations::Many
- Includes:
- Instantiators
- Included in:
- ManyEmbeddedProxy, ManyLinkedProxy
- Defined in:
- ripple/lib/ripple/associations/many.rb
Instance Method Summary (collapse)
- - (Object) <<(value) (also: #push, #concat)
- - (Object) count
- - (Object) reset
- - (Object) to_ary
Methods included from Instantiators
Instance Method Details
- (Object) <<(value) Also known as: push, concat
37 38 39 |
# File 'ripple/lib/ripple/associations/many.rb', line 37 def <<(value) raise NotImplementedError end |
- (Object) count
27 28 29 30 |
# File 'ripple/lib/ripple/associations/many.rb', line 27 def count load_target target.size end |
- (Object) reset
32 33 34 35 |
# File 'ripple/lib/ripple/associations/many.rb', line 32 def reset super @target = [] end |
- (Object) to_ary
22 23 24 25 |
# File 'ripple/lib/ripple/associations/many.rb', line 22 def to_ary load_target Array === target ? target.to_ary : Array(target) end |