Package org.opencastproject.util
Class SmartIterator<A>
java.lang.Object
org.opencastproject.util.SmartIterator<A>
Utility class for applying limit and offset to a map or collection
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapplyLimitAndOffset(Collection<A> unfilteredCollection) Apply limit and offset to a collection of typeSmartIteratorapplyLimitAndOffset(Map<String, A> map) Apply limit and offset to a map of value typeSmartIterator
-
Constructor Details
-
SmartIterator
public SmartIterator(int limit, int offset)
-
-
Method Details
-
applyLimitAndOffset
Apply limit and offset to a map of value typeSmartIterator- Parameters:
map- the map- Returns:
- the filtered map
-
applyLimitAndOffset
Apply limit and offset to a collection of typeSmartIterator- Parameters:
unfilteredCollection- the collection- Returns:
- the filtered list
-