Class: DuckRecord::Reflection::HasOneReflection
- Inherits:
-
AssociationReflection
- Object
- AbstractReflection
- MacroReflection
- AssociationReflection
- DuckRecord::Reflection::HasOneReflection
- Defined in:
- lib/duck_record/reflection.rb
Overview
:nodoc:
Instance Attribute Summary
Attributes inherited from AssociationReflection
#foreign_type, #parent_reflection, #type
Attributes inherited from MacroReflection
#duck_record, #name, #options, #plural_name, #scope
Instance Method Summary collapse
Methods inherited from AssociationReflection
#active_record_primary_key, #add_as_source, #alias_candidate, #association_foreign_key, #association_primary_key, #association_primary_key_type, #association_scope_cache, #belongs_to?, #chain, #check_preloadable!, #check_validity!, #clear_association_scope_cache, #collect_join_chain, #collection?, #compute_class, #constraints, #constructable?, #extensions, #foreign_key, #get_join_keys, #has_scope?, #initialize, #join_id_for, #join_keys, #join_scopes, #join_table, #klass, #klass_join_scope, #nested?, #primary_key_type, #quoted_table_name, #scope_chain, #scopes, #source_reflection, #table_name, #validate?
Methods inherited from MacroReflection
#==, #compute_class, #initialize, #klass
Methods inherited from AbstractReflection
#alias_candidate, #build_association, #check_validity!, #class_name
Constructor Details
This class inherits a constructor from DuckRecord::Reflection::AssociationReflection
Instance Method Details
#association_class ⇒ Object
645 646 647 |
# File 'lib/duck_record/reflection.rb', line 645 def association_class Associations::HasOneAssociation end |
#has_one? ⇒ Boolean
643 |
# File 'lib/duck_record/reflection.rb', line 643 def has_one?; true; end |
#macro ⇒ Object
641 |
# File 'lib/duck_record/reflection.rb', line 641 def macro; :has_one; end |