Class: Riddle::Configuration::RealtimeIndex
- Includes:
- IndexSettings
- Defined in:
- lib/riddle/configuration/realtime_index.rb
Instance Attribute Summary collapse
-
#rt_attr_bigint ⇒ Object
Returns the value of attribute rt_attr_bigint.
-
#rt_attr_bool ⇒ Object
Returns the value of attribute rt_attr_bool.
-
#rt_attr_float ⇒ Object
Returns the value of attribute rt_attr_float.
-
#rt_attr_json ⇒ Object
Returns the value of attribute rt_attr_json.
-
#rt_attr_multi ⇒ Object
Returns the value of attribute rt_attr_multi.
-
#rt_attr_multi_64 ⇒ Object
Returns the value of attribute rt_attr_multi_64.
-
#rt_attr_string ⇒ Object
Returns the value of attribute rt_attr_string.
-
#rt_attr_timestamp ⇒ Object
Returns the value of attribute rt_attr_timestamp.
-
#rt_attr_uint ⇒ Object
Returns the value of attribute rt_attr_uint.
-
#rt_field ⇒ Object
Returns the value of attribute rt_field.
-
#rt_mem_limit ⇒ Object
Returns the value of attribute rt_mem_limit.
Attributes included from IndexSettings
#bigram_freq_words, #bigram_index, #blend_chars, #blend_mode, #charset_dictpath, #charset_table, #charset_type, #dict, #docinfo, #enable_star, #exception_files, #expand_keywords, #global_idf, #ha_strategy, #hitless_words, #html_index_attrs, #html_remove_element_tags, #html_strip, #ignore_characters, #index_exact_words, #index_field_lengths, #index_sp, #index_zones, #infix_field_names, #inplace_docinfo_gap, #inplace_enable, #inplace_hit_gap, #inplace_reloc_factor, #inplace_write_factor, #min_infix_len, #min_prefix_len, #min_stemming_len, #min_word_len, #mlock, #morphologies, #name, #ngram_characters, #ngram_len, #ondisk_attrs, #ondisk_dict, #overshort_step, #path, #phrase_boundaries, #phrase_boundary_step, #prefix_field_names, #preopen, #regexp_filter, #rlp_context, #stopword_files, #stopword_step, #stopwords_unstemmed, #wordform_files
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name) ⇒ RealtimeIndex
constructor
A new instance of RealtimeIndex.
- #render ⇒ Object
- #type ⇒ Object
- #valid? ⇒ Boolean
Methods included from IndexSettings
#exceptions, #exceptions=, #html_remove_elements, #html_remove_elements=, #ignore_chars, #ignore_chars=, #infix_fields, #infix_fields=, #initialize_settings, #morphology, #morphology=, #ngram_chars, #ngram_chars=, #phrase_boundary, #phrase_boundary=, #prefix_fields, #prefix_fields=, #stopwords, #stopwords=, #wordforms, #wordforms=
Constructor Details
#initialize(name) ⇒ RealtimeIndex
Returns a new instance of RealtimeIndex.
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/riddle/configuration/realtime_index.rb', line 20 def initialize(name) @name = name @rt_field = [] @rt_attr_uint = [] @rt_attr_bigint = [] @rt_attr_float = [] @rt_attr_timestamp = [] @rt_attr_string = [] @rt_attr_multi = [] @rt_attr_multi_64 = [] @rt_attr_bool = [] @rt_attr_json = [] initialize_settings end |
Instance Attribute Details
#rt_attr_bigint ⇒ Object
Returns the value of attribute rt_attr_bigint.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_bigint @rt_attr_bigint end |
#rt_attr_bool ⇒ Object
Returns the value of attribute rt_attr_bool.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_bool @rt_attr_bool end |
#rt_attr_float ⇒ Object
Returns the value of attribute rt_attr_float.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_float @rt_attr_float end |
#rt_attr_json ⇒ Object
Returns the value of attribute rt_attr_json.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_json @rt_attr_json end |
#rt_attr_multi ⇒ Object
Returns the value of attribute rt_attr_multi.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_multi @rt_attr_multi end |
#rt_attr_multi_64 ⇒ Object
Returns the value of attribute rt_attr_multi_64.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_multi_64 @rt_attr_multi_64 end |
#rt_attr_string ⇒ Object
Returns the value of attribute rt_attr_string.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_string @rt_attr_string end |
#rt_attr_timestamp ⇒ Object
Returns the value of attribute rt_attr_timestamp.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def @rt_attr_timestamp end |
#rt_attr_uint ⇒ Object
Returns the value of attribute rt_attr_uint.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_attr_uint @rt_attr_uint end |
#rt_field ⇒ Object
Returns the value of attribute rt_field.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_field @rt_field end |
#rt_mem_limit ⇒ Object
Returns the value of attribute rt_mem_limit.
16 17 18 |
# File 'lib/riddle/configuration/realtime_index.rb', line 16 def rt_mem_limit @rt_mem_limit end |
Class Method Details
.settings ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/riddle/configuration/realtime_index.rb', line 8 def self.settings Riddle::Configuration::IndexSettings.settings + [ :rt_mem_limit, :rt_field, :rt_attr_uint, :rt_attr_bigint, :rt_attr_float, :rt_attr_timestamp, :rt_attr_string, :rt_attr_multi, :rt_attr_multi_64, :rt_attr_bool, :rt_attr_json ] end |
Instance Method Details
#render ⇒ Object
44 45 46 47 48 49 50 51 52 |
# File 'lib/riddle/configuration/realtime_index.rb', line 44 def render raise ConfigurationError unless valid? ( ["index #{name}", "{"] + settings_body + ["}", ""] ).join("\n") end |
#type ⇒ Object
36 37 38 |
# File 'lib/riddle/configuration/realtime_index.rb', line 36 def type "rt" end |
#valid? ⇒ Boolean
40 41 42 |
# File 'lib/riddle/configuration/realtime_index.rb', line 40 def valid? !(@name.nil? || @path.nil?) end |