Class: ActiveFedora::Relation::Merger
- Inherits:
-
Object
- Object
- ActiveFedora::Relation::Merger
- Defined in:
- lib/active_fedora/relation/merger.rb
Overview
:nodoc:
Instance Attribute Summary collapse
-
#other ⇒ Object
readonly
Returns the value of attribute other.
-
#relation ⇒ Object
readonly
Returns the value of attribute relation.
-
#values ⇒ Object
readonly
Returns the value of attribute values.
Instance Method Summary collapse
-
#initialize(relation, other) ⇒ Merger
constructor
A new instance of Merger.
- #merge ⇒ Object
Constructor Details
#initialize(relation, other) ⇒ Merger
Returns a new instance of Merger.
9 10 11 12 13 |
# File 'lib/active_fedora/relation/merger.rb', line 9 def initialize(relation, other) @relation = relation @values = other.values @other = other end |
Instance Attribute Details
#other ⇒ Object (readonly)
Returns the value of attribute other.
7 8 9 |
# File 'lib/active_fedora/relation/merger.rb', line 7 def other @other end |
#relation ⇒ Object (readonly)
Returns the value of attribute relation.
7 8 9 |
# File 'lib/active_fedora/relation/merger.rb', line 7 def relation @relation end |
#values ⇒ Object (readonly)
Returns the value of attribute values.
7 8 9 |
# File 'lib/active_fedora/relation/merger.rb', line 7 def values @values end |
Instance Method Details
#merge ⇒ Object
15 16 17 18 19 |
# File 'lib/active_fedora/relation/merger.rb', line 15 def merge # TODO: merge order relation.where_values += other.where_values relation end |