Class: Groonga::Command::TableCreate
- Defined in:
- lib/groonga/command/table-create.rb
Instance Attribute Summary
Attributes inherited from Base
#arguments, #command_name, #original_format, #original_source, #path_prefix
Class Method Summary collapse
Instance Method Summary collapse
-
#default_tokenizer ⇒ String?
Default tokenizer name or nil.
- #flags ⇒ Object
-
#key_type ⇒ String?
Key type name, nil for array no key table.
-
#key_with_sis? ⇒ Boolean
True if "KEY_WITH_SIS" is specified in #flags, false otherwise.
-
#name ⇒ String
The table name.
-
#normalizer ⇒ String?
Normalizer name or nil.
-
#table_dat_key? ⇒ Boolean
True if "TABLE_DAT_KEY" is specified in #flags, false otherwise.
-
#table_hash_key? ⇒ Boolean
True if "TABLE_HASH_KEY" is specified in #flags, false otherwise.
-
#table_no_key? ⇒ Boolean
True if "TABLE_NO_KEY" is specified in #flags, false otherwise.
-
#table_pat_key? ⇒ Boolean
True if "TABLE_PAT_KEY" is specified in #flags, false otherwise.
-
#token_filters ⇒ ::Array<String>
Token filter names.
-
#value_type ⇒ String?
Value type name,
nil
for no value table.
Methods inherited from Base
#==, #[], #[]=, #command_format?, #initialize, #key?, #output_type, #request_id, #to_command_format, #to_uri_format, #uri_format?
Constructor Details
This class inherits a constructor from Groonga::Command::Base
Class Method Details
.command_name ⇒ Object
23 24 25 |
# File 'lib/groonga/command/table-create.rb', line 23 def command_name "table_create" end |
.parameter_names ⇒ Object
27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/groonga/command/table-create.rb', line 27 def parameter_names [ :name, :flags, :key_type, :value_type, :default_tokenizer, :normalizer, :token_filters, ] end |
Instance Method Details
#default_tokenizer ⇒ String?
Returns Default tokenizer name or nil.
105 106 107 |
# File 'lib/groonga/command/table-create.rb', line 105 def default_tokenizer self[:default_tokenizer] end |
#flags ⇒ Object
64 65 66 |
# File 'lib/groonga/command/table-create.rb', line 64 def flags @flags ||= flags_value(:flags) end |
#key_type ⇒ String?
Returns Key type name, nil for array no key table.
51 52 53 |
# File 'lib/groonga/command/table-create.rb', line 51 def key_type self[:key_type] end |
#key_with_sis? ⇒ Boolean
Returns true if "KEY_WITH_SIS" is specified in #flags, false otherwise.
99 100 101 |
# File 'lib/groonga/command/table-create.rb', line 99 def key_with_sis? flags.include?("KEY_WITH_SIS") end |
#name ⇒ String
Returns The table name.
45 46 47 |
# File 'lib/groonga/command/table-create.rb', line 45 def name self[:name] end |
#normalizer ⇒ String?
Returns Normalizer name or nil.
111 112 113 |
# File 'lib/groonga/command/table-create.rb', line 111 def normalizer self[:normalizer] end |
#table_dat_key? ⇒ Boolean
Returns true if "TABLE_DAT_KEY" is specified in #flags, false otherwise.
92 93 94 |
# File 'lib/groonga/command/table-create.rb', line 92 def table_dat_key? flags.include?("TABLE_DAT_KEY") end |
#table_hash_key? ⇒ Boolean
Returns true if "TABLE_HASH_KEY" is specified in #flags, false otherwise.
78 79 80 |
# File 'lib/groonga/command/table-create.rb', line 78 def table_hash_key? flags.include?("TABLE_HASH_KEY") end |
#table_no_key? ⇒ Boolean
Returns true if "TABLE_NO_KEY" is specified in #flags, false otherwise.
71 72 73 |
# File 'lib/groonga/command/table-create.rb', line 71 def table_no_key? flags.include?("TABLE_NO_KEY") end |
#table_pat_key? ⇒ Boolean
Returns true if "TABLE_PAT_KEY" is specified in #flags, false otherwise.
85 86 87 |
# File 'lib/groonga/command/table-create.rb', line 85 def table_pat_key? flags.include?("TABLE_PAT_KEY") end |
#token_filters ⇒ ::Array<String>
Returns Token filter names.
117 118 119 |
# File 'lib/groonga/command/table-create.rb', line 117 def token_filters @token_filters ||= array_value(:token_filters) end |
#value_type ⇒ String?
Returns Value type name, nil
for no value
table. Double array trie table always returns nil
because
double array trie table doesn't support value.
60 61 62 |
# File 'lib/groonga/command/table-create.rb', line 60 def value_type self[:value_type] end |