Class: ThinkingSphinx::IndexSet

Inherits:
Object
  • Object
show all
Includes:
Enumerable
Defined in:
lib/thinking_sphinx/index_set.rb

Instance Method Summary collapse

Constructor Details

#initialize(classes, index_names, configuration = nil) ⇒ IndexSet



6
7
8
9
10
# File 'lib/thinking_sphinx/index_set.rb', line 6

def initialize(classes, index_names, configuration = nil)
  @classes       = classes || []
  @index_names   = index_names
  @configuration = configuration || ThinkingSphinx::Configuration.instance
end

Instance Method Details

#ancestorsObject



12
13
14
# File 'lib/thinking_sphinx/index_set.rb', line 12

def ancestors
  classes_and_ancestors - classes
end

#to_aObject



16
17
18
# File 'lib/thinking_sphinx/index_set.rb', line 16

def to_a
  indices
end