Class OrQuery<T>

  • All Implemented Interfaces:
    Query<T>

    public class OrQuery<T>
    extends Object
    implements Query<T>
    Deprecated.
    Use Context.getObjectsAsStream(Class) and the Java 8+ streaming API Stream instead.
    A query whose result is the union of its sub queries.
    Version:
    $Revision$ $Date$
    Author:
    Nick Collier
    • Constructor Detail

      • OrQuery

        public OrQuery​(Query<T> query1,
                       Query<T> query2)
        Deprecated.
        Creates an OrQuery from the two sub-queries.
        Parameters:
        query1 -
        query2 -
    • Method Detail

      • query

        public Iterable<T> query()
        Deprecated.
        Gets the union of the two queries specified in the constructor.
        Specified by:
        query in interface Query<T>
        Returns:
        an iterable over the objects in the union of the two queries specified in the constructor.
      • query

        public Iterable<T> query​(Iterable<T> set)
        Deprecated.
        Returns an iterable over the union of the two queries specified in the constructor where the results of that union are in the iterable parameter.
        Specified by:
        query in interface Query<T>
        Parameters:
        set -
        Returns:
        an iterable over the union of the two queries specified in the constructor where the results of that union are in the iterable parameter.