Class: Riddle::Configuration::Common

Inherits:
Section
  • Object
show all
Defined in:
lib/riddle/configuration/common.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Section

#valid?

Class Method Details

.settingsObject


4
5
6
7
8
9
10
# File 'lib/riddle/configuration/common.rb', line 4

def self.settings
  [
    :lemmatizer_base, :json_autoconv_numbers, :json_autoconv_keynames,
    :on_json_attr_error, :rlp_root, :rlp_environment, :rlp_max_batch_size,
    :rlp_max_batch_docs
  ]
end

Instance Method Details

#renderObject

Raises:


14
15
16
17
18
19
20
21
22
23
# File 'lib/riddle/configuration/common.rb', line 14

def render
  return unless common_sphinx_configuration
  raise ConfigurationError unless valid?

  (
    ["common", "{"] +
    settings_body +
    ["}", ""]
  ).join("\n")
end