Class: Formed::Reflection::RuntimeReflection
Overview
Instance Method Summary
collapse
#alias_candidate, #build_association, #build_scope, #chain, #check_validity_of_inverse!, #class_name, #constraints, #inverse_of, #scopes, #strict_loading?, #strict_loading_violation_message, #table_name, #through_reflection?
Constructor Details
#initialize(reflection, association) ⇒ RuntimeReflection
Returns a new instance of RuntimeReflection.
759
760
761
762
|
# File 'lib/formed/reflection.rb', line 759
def initialize(reflection, association)
@reflection = reflection
@association = association
end
|
Instance Method Details
#aliased_table ⇒ Object
768
769
770
|
# File 'lib/formed/reflection.rb', line 768
def aliased_table
klass.arel_table
end
|
#all_includes ⇒ Object
776
777
778
|
# File 'lib/formed/reflection.rb', line 776
def all_includes
yield
end
|
#join_primary_key(klass = self.klass) ⇒ Object
772
773
774
|
# File 'lib/formed/reflection.rb', line 772
def join_primary_key(klass = self.klass)
@reflection.join_primary_key(klass)
end
|
#klass ⇒ Object
764
765
766
|
# File 'lib/formed/reflection.rb', line 764
def klass
@association.klass
end
|