Class Filter

java.lang.Object
com.googlecode.objectify.cmd.Filter

public abstract class Filter extends Object
Gives us the ability to compose arbitrarily complex filters with OR and AND sections.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static Filter
    and(Filter... filters)
    Combine an arbitrary list of filter conditions.
    abstract com.google.cloud.datastore.StructuredQuery.Filter
    Convert to a low level API filter.
    static Filter
    equalTo(String property, Object value)
    Create a filter condition that requires the property to equal the scalar value.
    static Filter
    greaterThan(String property, Object value)
    Create a filter condition that requires the property to be greater than the scalar value
    static Filter
    Create a filter condition that requires the property to be greater than or equal to scalar value
    static Filter
    in(String property, Object value)
    Create a filter condition that requires the property to be equal to at least one of a list of scalar values.
    static Filter
    lessThan(String property, Object value)
    Create a filter condition that requires the property to be less than the scalar value
    static Filter
    lessThanOrEqualTo(String property, Object value)
    Create a filter condition that requires the property to be less than or equal to the scalar value
    static Filter
    notEqualTo(String property, Object value)
    Create a filter condition that requires the property to not be equal to the scalar value.
    static Filter
    notIn(String property, Object value)
    Create a filter condition that requires the property to NOT be equal to any of a list of scalar values.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Filter

      public Filter()
  • Method Details

    • equalTo

      public static Filter equalTo(String property, Object value)
      Create a filter condition that requires the property to equal the scalar value.
    • notEqualTo

      public static Filter notEqualTo(String property, Object value)
      Create a filter condition that requires the property to not be equal to the scalar value.
    • greaterThan

      public static Filter greaterThan(String property, Object value)
      Create a filter condition that requires the property to be greater than the scalar value
    • greaterThanOrEqualTo

      public static Filter greaterThanOrEqualTo(String property, Object value)
      Create a filter condition that requires the property to be greater than or equal to scalar value
    • lessThan

      public static Filter lessThan(String property, Object value)
      Create a filter condition that requires the property to be less than the scalar value
    • lessThanOrEqualTo

      public static Filter lessThanOrEqualTo(String property, Object value)
      Create a filter condition that requires the property to be less than or equal to the scalar value
    • in

      public static Filter in(String property, Object value)
      Create a filter condition that requires the property to be equal to at least one of a list of scalar values.
      Parameters:
      value - must be an array or collection
    • notIn

      public static Filter notIn(String property, Object value)
      Create a filter condition that requires the property to NOT be equal to any of a list of scalar values.
      Parameters:
      value - must be an array or collection
    • and

      public static Filter and(Filter... filters)
      Combine an arbitrary list of filter conditions. They can be nested.
    • convert

      public abstract com.google.cloud.datastore.StructuredQuery.Filter convert(ObjectifyImpl ofyImpl)
      Convert to a low level API filter.