Class: Parse::Constraint::NotInQueryConstraint

Inherits:
Parse::Constraint show all
Defined in:
lib/parse/query/constraints.rb

Overview

Equivalent to the `$notInQuery` Parse query operation. Useful if you want to retrieve objects where a field contains an object that does not match another query. This is the inverse of the InQueryConstraint.

q.where :field.excludes => query

q.where :post.excludes => Post.where(:image.exists => true

Instance Attribute Summary

Attributes inherited from Parse::Constraint

#operand, #operation, #operator, #value

Instance Method Summary collapse

Methods inherited from Parse::Constraint

#as_json, #build, contraint_keyword, create, #formatted_value, formatted_value, #initialize, #key, #precedence, register, #to_s

Constructor Details

This class inherits a constructor from Parse::Constraint

Instance Method Details

#excludesNotInQueryConstraint

A registered method on a symbol to create the constraint. Maps to Parse operator “$notInQuery”.

Examples:

q.where :field.excludes => query

Returns:

# File 'lib/parse/query/constraints.rb', line 572

#not_in_queryNotInQueryConstraint

Alias for #excludes



581
# File 'lib/parse/query/constraints.rb', line 581

contraint_keyword :$notInQuery