Class: Liquigen::CreateIndex
- Defined in:
- lib/liquigen/create_index.rb
Instance Attribute Summary collapse
-
#columns ⇒ Object
Returns the value of attribute columns.
-
#index_name ⇒ Object
Returns the value of attribute index_name.
-
#table_name ⇒ Object
Returns the value of attribute table_name.
Instance Method Summary collapse
-
#initialize(table_name) ⇒ CreateIndex
constructor
A new instance of CreateIndex.
Constructor Details
#initialize(table_name) ⇒ CreateIndex
Returns a new instance of CreateIndex.
9 10 11 12 13 |
# File 'lib/liquigen/create_index.rb', line 9 def initialize(table_name) self.table_name = table_name&.underscore&.pluralize self.index_name = '' self.columns = [] end |
Instance Attribute Details
#columns ⇒ Object
Returns the value of attribute columns.
7 8 9 |
# File 'lib/liquigen/create_index.rb', line 7 def columns @columns end |
#index_name ⇒ Object
Returns the value of attribute index_name.
6 7 8 |
# File 'lib/liquigen/create_index.rb', line 6 def index_name @index_name end |
#table_name ⇒ Object
Returns the value of attribute table_name.
5 6 7 |
# File 'lib/liquigen/create_index.rb', line 5 def table_name @table_name end |