Class: Vorpal::OwnedObjectVisitor
- Inherits:
-
Object
- Object
- Vorpal::OwnedObjectVisitor
- Includes:
- AggregateVisitorTemplate
- Defined in:
- lib/vorpal/aggregate_utils.rb
Instance Attribute Summary collapse
-
#owned_objects ⇒ Object
readonly
Returns the value of attribute owned_objects.
Instance Method Summary collapse
- #continue_traversal?(association_config) ⇒ Boolean
-
#initialize ⇒ OwnedObjectVisitor
constructor
A new instance of OwnedObjectVisitor.
- #visit_object(object, config) ⇒ Object
Constructor Details
#initialize ⇒ OwnedObjectVisitor
Returns a new instance of OwnedObjectVisitor.
26 27 28 |
# File 'lib/vorpal/aggregate_utils.rb', line 26 def initialize @owned_objects = [] end |
Instance Attribute Details
#owned_objects ⇒ Object (readonly)
Returns the value of attribute owned_objects.
24 25 26 |
# File 'lib/vorpal/aggregate_utils.rb', line 24 def owned_objects @owned_objects end |
Instance Method Details
#continue_traversal?(association_config) ⇒ Boolean
34 35 36 |
# File 'lib/vorpal/aggregate_utils.rb', line 34 def continue_traversal?(association_config) association_config.owned end |
#visit_object(object, config) ⇒ Object
30 31 32 |
# File 'lib/vorpal/aggregate_utils.rb', line 30 def visit_object(object, config) @owned_objects << object end |