Class PaginationAction.PaginationIterator<E>

All Implemented Interfaces:
Enclosing interface:
PaginationAction<T,M extends PaginationAction<T,M>>

public static class PaginationAction.PaginationIterator<E> extends Object implements Iterator<E>
Iterator implementation for a PaginationAction.
This iterator will first iterate over all currently cached entities and continue to retrieve new entities as needed.

To retrieve new entities after reaching the end of the current cache, this iterator will request a List of new entities through a call of RestAction.complete().
It is recommended to use the highest possible limit for this task. (see PaginationAction.limit(int))

  • Constructor Details

  • Method Details

    • hasNext

      public boolean hasNext()
      Specified by:
      hasNext in interface Iterator<E>
    • next

      public E next()
      Specified by:
      next in interface Iterator<E>