Package ca.uhn.fhir.util
Class StopLimitAccumulator<T>
java.lang.Object
ca.uhn.fhir.util.StopLimitAccumulator<T>
- Type Parameters:
T
- the type of object being streamed
This class collects items from a stream to a given limit and know whether there are
still more items beyond that limit.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> StopLimitAccumulator
<T> fromStreamAndLimit
(Stream<T> theItemStream, long theLimit) boolean
-
Method Details
-
fromStreamAndLimit
public static <T> StopLimitAccumulator<T> fromStreamAndLimit(@Nonnull Stream<T> theItemStream, long theLimit) -
isTruncated
-
getItemList
-