Class: SQL::Sqlite::Table

Inherits:
Table
  • Object
show all
Defined in:
lib/dm-migrations/sql/sqlite.rb

Instance Attribute Summary

Attributes inherited from Table

#columns, #name

Instance Method Summary collapse

Methods inherited from Table

#column, #to_s

Constructor Details

#initialize(adapter, table_name) ⇒ Table

Returns a new instance of Table.



38
39
40
41
42
43
44
# File 'lib/dm-migrations/sql/sqlite.rb', line 38

def initialize(adapter, table_name)
  super()
  @columns = []
  adapter.table_info(table_name).each do |col_struct|
    @columns << SQL::Sqlite::Column.new(col_struct)
  end
end