Class: Sunspot::Query::Restriction::AllOf

Inherits:
Base
  • Object
show all
Defined in:
lib/sunspot/query/restriction.rb

Overview

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

Constant Summary

Constants inherited from Base

Base::RESERVED_WORDS

Instance Method Summary collapse

Methods inherited from Base

#initialize, #negate, #to_boolean_phrase, #to_negated_boolean_phrase, #to_params, #to_positive_boolean_phrase

Methods included from Filter

#tag, #to_filter_query

Constructor Details

This class inherits a constructor from Sunspot::Query::Restriction::Base

Instance Method Details

#negated?Boolean

Returns:

  • (Boolean)


330
331
332
333
334
335
336
# File 'lib/sunspot/query/restriction.rb', line 330

def negated?
  if @value.empty?
    false
  else
    super
  end
end