Class: ActiveFedora::Orders::Reflection
- Inherits:
-
Reflection::AssociationReflection
- Object
- Reflection::AssociationReflection
- ActiveFedora::Orders::Reflection
- Defined in:
- lib/active_fedora/orders/reflection.rb
Class Method Summary collapse
Instance Method Summary collapse
- #association_class ⇒ Object
- #class_name ⇒ Object
- #collection? ⇒ Boolean
- #klass ⇒ Object
- #unordered_reflection ⇒ Object
Class Method Details
.create(macro, name, scope, options, active_fedora) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 |
# File 'lib/active_fedora/orders/reflection.rb', line 4 def create(macro, name, scope, , active_fedora) klass = case macro when :aggregation Reflection when :filter ActiveFedora::Filter::Reflection when :orders ActiveFedora::Orders::Reflection end reflection = klass.new(macro, name, scope, , active_fedora) ActiveFedora::Reflection.add_reflection(active_fedora, name, reflection) reflection end |
Instance Method Details
#association_class ⇒ Object
18 19 20 |
# File 'lib/active_fedora/orders/reflection.rb', line 18 def association_class Association end |
#class_name ⇒ Object
26 27 28 |
# File 'lib/active_fedora/orders/reflection.rb', line 26 def class_name klass.to_s end |
#collection? ⇒ Boolean
22 23 24 |
# File 'lib/active_fedora/orders/reflection.rb', line 22 def collection? true end |
#klass ⇒ Object
34 35 36 |
# File 'lib/active_fedora/orders/reflection.rb', line 34 def klass ActiveFedora::Orders::ListNode end |
#unordered_reflection ⇒ Object
30 31 32 |
# File 'lib/active_fedora/orders/reflection.rb', line 30 def unordered_reflection [:unordered_reflection] end |