Class: Riddle::Configuration::Parser

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

Defined Under Namespace

Classes: InnerParser

Constant Summary collapse

SOURCE_CLASSES =
{
  'mysql'    => Riddle::Configuration::SQLSource,
  'pgsql'    => Riddle::Configuration::SQLSource,
  'mssql'    => Riddle::Configuration::SQLSource,
  'xmlpipe'  => Riddle::Configuration::XMLSource,
  'xmlpipe2' => Riddle::Configuration::XMLSource,
  'odbc'     => Riddle::Configuration::SQLSource,
  'tsvpipe'  => Riddle::Configuration::TSVSource
}
INDEX_CLASSES =
{
  'plain'       => Riddle::Configuration::Index,
  'distributed' => Riddle::Configuration::DistributedIndex,
  'rt'          => Riddle::Configuration::RealtimeIndex,
  'template'    => Riddle::Configuration::TemplateIndex
}

Instance Method Summary collapse

Constructor Details

#initialize(input) ⇒ Parser


22
23
24
# File 'lib/riddle/configuration/parser.rb', line 22

def initialize(input)
  @input   = input
end

Instance Method Details

#parse!Object


26
27
28
29
30
31
32
33
34
35
36
# File 'lib/riddle/configuration/parser.rb', line 26

def parse!
  set_common
  set_indexer
  set_searchd
  set_sources
  set_indices

  add_orphan_sources

  configuration
end