Class: MysqlWarmup::Index
- Inherits:
-
Object
- Object
- MysqlWarmup::Index
- Defined in:
- lib/mysql_warmup/index.rb
Constant Summary collapse
- QUERY_TEMPLATE =
'select %s from %s where %s'.freeze
Instance Attribute Summary collapse
-
#query_string ⇒ Object
readonly
Returns the value of attribute query_string.
Instance Method Summary collapse
-
#initialize(table_name, column_name, column_type, column_key) ⇒ Index
constructor
A new instance of Index.
Constructor Details
#initialize(table_name, column_name, column_type, column_key) ⇒ Index
6 7 8 9 10 11 12 13 |
# File 'lib/mysql_warmup/index.rb', line 6 def initialize(table_name, column_name, column_type, column_key) @table_name = table_name @column_name = column_name @column_type = column_type @column_key = column_key @query_string = build_query_string(@table_name, @column_name, @column_type, @column_key) end |
Instance Attribute Details
#query_string ⇒ Object (readonly)
Returns the value of attribute query_string.
4 5 6 |
# File 'lib/mysql_warmup/index.rb', line 4 def query_string @query_string end |