Class: Kibutsu::ForeignKeyColumn

Inherits:
Object
  • Object
show all
Defined in:
lib/kibutsu/foreign_key_column.rb

Overview

Corresponds to a foreign key column in the database.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(source_table, name, target_table) ⇒ ForeignKeyColumn

Returns a new instance of ForeignKeyColumn.



4
5
6
7
8
# File 'lib/kibutsu/foreign_key_column.rb', line 4

def initialize(source_table, name, target_table)
  @source_table = source_table
  @name = name
  @target_table = target_table
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



10
11
12
# File 'lib/kibutsu/foreign_key_column.rb', line 10

def name
  @name
end

#source_tableObject (readonly)

Returns the value of attribute source_table.



10
11
12
# File 'lib/kibutsu/foreign_key_column.rb', line 10

def source_table
  @source_table
end

#target_tableObject (readonly)

Returns the value of attribute target_table.



10
11
12
# File 'lib/kibutsu/foreign_key_column.rb', line 10

def target_table
  @target_table
end