Method: ActiveEntity::Reflection::ClassMethods#reflect_on_association
- Defined in:
- lib/active_entity/reflection.rb
#reflect_on_association(association) ⇒ Object
Returns the AssociationReflection object for the association (use the symbol).
Account.reflect_on_association(:owner) # returns the owner AssociationReflection
Invoice.reflect_on_association(:line_items).macro # returns :has_many
119 120 121 |
# File 'lib/active_entity/reflection.rb', line 119 def reflect_on_association(association) reflections[association.to_s] end |