Class IdSeekPageIterator<T extends com.broadleafcommerce.data.tracking.core.Trackable>
java.lang.Object
com.broadleafcommerce.promotion.offer.service.helper.IdSeekPageIterator<T>
- All Implemented Interfaces:
Iterator<T>
public class IdSeekPageIterator<T extends com.broadleafcommerce.data.tracking.core.Trackable>
extends Object
implements Iterator<T>
Iterator that performs "seek" pagination.
See here for a description of the seek pagination strategy.
Externally, this can be used as a regular iterator that will return one element at a time until there are none left. However, the implementation will retrieve results in batches/pages from a given source when needed. This allows for a combination of lazy loading (to avoid loading large datasets as a whole, which can overwhelm resources) and batching (to avoid excessive round trips due to lazy loading).
To perform the batching/pagination, this iterator requires a data source capable of performing seek pagination.
-
Constructor Details
-
IdSeekPageIterator
-
-
Method Details