Class FilterIterators


  • public class FilterIterators
    extends Object
    Filtering iterators that are useful for queries with limit, offset, order by, or distinct.
    • Method Detail

      • checkMemoryLimit

        public static void checkMemoryLimit​(long count,
                                            QueryLimits settings)
        Verify the number of in-memory nodes is below the limit.
        Parameters:
        count - the number of nodes
        settings - the query engine settings
        Throws:
        UnsupportedOperationException - if the limit was exceeded
      • checkReadLimit

        public static void checkReadLimit​(long count,
                                          QueryLimits settings)
        Verify the number of node read operations is below the limit.
        Parameters:
        count - the number of read operations
        settings - the query engine settings
        Throws:
        RuntimeNodeTraversalException - if the limit was exceeded
      • newDistinct

        public static <K> org.apache.jackrabbit.oak.query.FilterIterators.DistinctIterator<K> newDistinct​(Iterator<K> it,
                                                                                                          QueryLimits settings)
      • newLimit

        public static <K> Iterator<K> newLimit​(Iterator<K> it,
                                               long limit)
      • newOffset

        public static <K> Iterator<K> newOffset​(Iterator<K> it,
                                                long offset)