Class: ActiveRecord::Associations::JoinDependency::JoinBase

Inherits:
JoinPart
  • Object
show all
Defined in:
lib/active_record/associations/join_dependency/join_base.rb

Overview

:nodoc:

Instance Attribute Summary

Attributes inherited from JoinPart

#active_record

Instance Method Summary collapse

Methods inherited from JoinPart

#aliased_primary_key, #aliased_table, #column_names_with_alias, #extract_record, #initialize, #instantiate, #record_id

Constructor Details

This class inherits a constructor from ActiveRecord::Associations::JoinDependency::JoinPart

Instance Method Details

#==(other) ⇒ Object



5
6
7
8
# File 'lib/active_record/associations/join_dependency/join_base.rb', line 5

def ==(other)
  other.class == self.class &&
    other.active_record == active_record
end

#aliased_prefixObject



10
11
12
# File 'lib/active_record/associations/join_dependency/join_base.rb', line 10

def aliased_prefix
  "t0"
end

#aliased_table_nameObject



18
19
20
# File 'lib/active_record/associations/join_dependency/join_base.rb', line 18

def aliased_table_name
  active_record.table_name
end

#tableObject



14
15
16
# File 'lib/active_record/associations/join_dependency/join_base.rb', line 14

def table
  Arel::Table.new(table_name, arel_engine)
end