Class: Groonga::Client::Response::Schema::Column
- Inherits:
-
Hash
- Object
- Hash
- Groonga::Client::Response::Schema::Column
- Includes:
- Hashie::Extensions::MethodAccess
- Defined in:
- lib/groonga/client/response/schema.rb
Overview
Instance Method Summary collapse
- #[]=(key, value) ⇒ Object
- #have_full_text_search_index? ⇒ Boolean
-
#initialize(schema, raw_column) ⇒ Column
constructor
A new instance of Column.
Constructor Details
#initialize(schema, raw_column) ⇒ Column
Returns a new instance of Column.
192 193 194 195 196 197 198 |
# File 'lib/groonga/client/response/schema.rb', line 192 def initialize(schema, raw_column) @schema = schema super() raw_column.each do |key, value| self[key] = value end end |
Instance Method Details
#[]=(key, value) ⇒ Object
200 201 202 203 204 205 206 207 208 209 210 |
# File 'lib/groonga/client/response/schema.rb', line 200 def []=(key, value) case key.to_sym when :indexes super(key, coerce_indexes(value)) when :value_type value = ValueType.new(value) unless value.nil? super(key, value) else super end end |
#have_full_text_search_index? ⇒ Boolean
212 213 214 215 216 |
# File 'lib/groonga/client/response/schema.rb', line 212 def have_full_text_search_index? indexes.any? do |index| index.full_text_searchable? end end |