Class: ActiveRecordSchema::Join

Inherits:
Object
  • Object
show all
Defined in:
lib/active_record_schema/join.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(table, key1, key2, index = true) ⇒ Join

Returns a new instance of Join.



4
5
6
7
8
9
# File 'lib/active_record_schema/join.rb', line 4

def initialize(table, key1, key2, index = true)
  @table = table
  @key1 = key1
  @key2 = key2
  @index = index
end

Instance Attribute Details

#indexObject (readonly)

Returns the value of attribute index.



3
4
5
# File 'lib/active_record_schema/join.rb', line 3

def index
  @index
end

#key1Object (readonly)

Returns the value of attribute key1.



3
4
5
# File 'lib/active_record_schema/join.rb', line 3

def key1
  @key1
end

#key2Object (readonly)

Returns the value of attribute key2.



3
4
5
# File 'lib/active_record_schema/join.rb', line 3

def key2
  @key2
end

#tableObject (readonly)

Returns the value of attribute table.



3
4
5
# File 'lib/active_record_schema/join.rb', line 3

def table
  @table
end