class Sunspot::Query::Restriction::AllOf

Results must have field with values matching all values in given collection (only makes sense for fields with multiple values)

Public Instance Methods

negated?() click to toggle source
Calls superclass method
# File lib/sunspot/query/restriction.rb, line 329
def negated?
  if @value.empty?
    false
  else
    super
  end
end

Private Instance Methods

to_solr_conditional() click to toggle source
# File lib/sunspot/query/restriction.rb, line 339
def to_solr_conditional
  if @value.empty?
    "[* TO *]"
  else
    "(#{@value.map { |v| solr_value v } * ' AND '})"
  end
end