Class: Groonga::Client::Response::Schema::Table

Inherits:
Hash
  • Object
show all
Includes:
Hashie::Extensions::MethodAccess
Defined in:
lib/groonga/client/response/schema.rb

Overview

Since:

  • 0.2.2

Instance Method Summary collapse

Constructor Details

#initialize(schema) ⇒ Table

Returns a new instance of Table.

Since:

  • 0.2.2



253
254
255
256
# File 'lib/groonga/client/response/schema.rb', line 253

def initialize(schema)
  @schema = schema
  super()
end

Instance Method Details

#[]=(key, value) ⇒ Object

Since:

  • 0.2.2



258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
# File 'lib/groonga/client/response/schema.rb', line 258

def []=(key, value)
  case key.to_sym
  when :key_type
    super(key, coerce_key_type(value))
  when :tokenizer
    super(key, coerce_tokenizer(value))
  when :normalizer
    super(key, coerce_normalizer(value))
  when :columns
    super(key, coerce_columns(value))
  when :indexes
    super(key, coerce_indexes(value))
  when :command
    super(key, Command.new(value))
  else
    super
  end
end

#have_full_text_search_index?Boolean

Returns:

  • (Boolean)

Since:

  • 0.2.2



277
278
279
280
281
# File 'lib/groonga/client/response/schema.rb', line 277

def have_full_text_search_index?
  indexes.any? do |index|
    index.full_text_searchable?
  end
end