Class: Groonga::Client::Response::Schema::Index
- Inherits:
-
Hash
- Object
- Hash
- Groonga::Client::Response::Schema::Index
- Includes:
- Hashie::Extensions::MethodAccess
- Defined in:
- lib/groonga/client/response/schema.rb
Overview
Instance Method Summary collapse
- #[]=(key, value) ⇒ Object
- #column ⇒ Object
- #full_text_searchable? ⇒ Boolean
-
#initialize(schema, raw_index) ⇒ Index
constructor
A new instance of Index.
Constructor Details
#initialize(schema, raw_index) ⇒ Index
Returns a new instance of Index.
175 176 177 178 179 180 181 |
# File 'lib/groonga/client/response/schema.rb', line 175 def initialize(schema, raw_index) @schema = schema super() raw_index.each do |key, value| self[key] = value end end |
Instance Method Details
#[]=(key, value) ⇒ Object
183 184 185 186 187 188 189 190 |
# File 'lib/groonga/client/response/schema.rb', line 183 def []=(key, value) case key.to_sym when :table super(key, coerce_table(value)) else super end end |
#column ⇒ Object
192 193 194 195 196 197 198 199 |
# File 'lib/groonga/client/response/schema.rb', line 192 def column column_name = name if column_name.nil? column_name else table.columns[column_name] end end |
#full_text_searchable? ⇒ Boolean
201 202 203 |
# File 'lib/groonga/client/response/schema.rb', line 201 def full_text_searchable? table.tokenizer and column.position end |