Class AbstractLazyIterable<T>
java.lang.Object
org.eclipse.collections.impl.AbstractRichIterable<T>
org.eclipse.collections.impl.lazy.AbstractLazyIterable<T>
- All Implemented Interfaces:
Iterable<T>,InternalIterable<T>,LazyIterable<T>,RichIterable<T>
- Direct Known Subclasses:
ChunkBooleanIterable,ChunkByteIterable,ChunkCharIterable,ChunkDoubleIterable,ChunkFloatIterable,ChunkIntIterable,ChunkIterable,ChunkLongIterable,ChunkShortIterable,CollectBooleanToObjectIterable,CollectByteToObjectIterable,CollectCharToObjectIterable,CollectDoubleToObjectIterable,CollectFloatToObjectIterable,CollectIntToObjectIterable,CollectIterable,CollectLongToObjectIterable,CollectShortToObjectIterable,CompositeIterable,DistinctIterable,DropIterable,DropWhileIterable,FlatCollectBooleanToObjectIterable,FlatCollectByteToObjectIterable,FlatCollectCharToObjectIterable,FlatCollectDoubleToObjectIterable,FlatCollectFloatToObjectIterable,FlatCollectIntToObjectIterable,FlatCollectIterable,FlatCollectLongToObjectIterable,FlatCollectShortToObjectIterable,Interval,LazyIterableAdapter,RejectIterable,ReverseIterable,SelectInstancesOfIterable,SelectIterable,TakeIterable,TakeWhileIterable,TapIterable,ZipIterable,ZipWithIndexIterable
public abstract class AbstractLazyIterable<T>
extends AbstractRichIterable<T>
implements LazyIterable<T>
AbstractLazyIterable provides a base from which deferred iterables such as SelectIterable,
RejectIterable and CollectIterable can be derived.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionasLazy()chunk(int size) <V> LazyIterable<V>collectBoolean(BooleanFunction<? super T> booleanFunction) collectByte(ByteFunction<? super T> byteFunction) collectChar(CharFunction<? super T> charFunction) collectDouble(DoubleFunction<? super T> doubleFunction) collectFloat(FloatFunction<? super T> floatFunction) <V> LazyIterable<V>collectInt(IntFunction<? super T> intFunction) collectLong(LongFunction<? super T> longFunction) collectShort(ShortFunction<? super T> shortFunction) <P,V> LazyIterable<V> collectWith(Function2<? super T, ? super P, ? extends V> function, P parameter) concatenate(Iterable<T> iterable) distinct()drop(int count) <V> LazyIterable<V>flatCollect(Function<? super T, ? extends Iterable<V>> function) getFirst()getLast()getOnly()groupByEach(Function<? super T, ? extends Iterable<V>> function) <V> MapIterable<V,T> groupByUniqueKey(Function<? super T, ? extends V> function) <R extends Collection<T>>
Rinto(R target) booleanisEmpty()<V extends Comparable<? super V>>
Optional<T>maxByOptional(Function<? super T, ? extends V> function) maxOptional(Comparator<? super T> comparator) <V extends Comparable<? super V>>
Optional<T>minByOptional(Function<? super T, ? extends V> function) minOptional(Comparator<? super T> comparator) <P> PartitionMutableList<T>partitionWith(Predicate2<? super T, ? super P> predicate, P parameter) <P> LazyIterable<T>rejectWith(Predicate2<? super T, ? super P> predicate, P parameter) <S> LazyIterable<S>selectInstancesOf(Class<S> clazz) <P> LazyIterable<T>selectWith(Predicate2<? super T, ? super P> predicate, P parameter) intsize()<V> ObjectDoubleMap<V>sumByDouble(Function<? super T, ? extends V> groupBy, DoubleFunction<? super T> function) <V> ObjectDoubleMap<V>sumByFloat(Function<? super T, ? extends V> groupBy, FloatFunction<? super T> function) <V> ObjectLongMap<V>sumByInt(Function<? super T, ? extends V> groupBy, IntFunction<? super T> function) <V> ObjectLongMap<V>sumByLong(Function<? super T, ? extends V> groupBy, LongFunction<? super T> function) take(int count) toStack()<S> LazyIterable<Pair<T,S>> Methods inherited from class org.eclipse.collections.impl.AbstractRichIterable
allSatisfy, allSatisfyWith, anySatisfy, anySatisfyWith, appendString, appendString, collect, collectIf, collectWith, contains, containsAll, containsAllArguments, containsAllIterable, count, countByEach, countWith, detect, detectOptional, detectWith, detectWithIfNone, detectWithOptional, flatCollect, forEach, forEachWith, forEachWithIndex, groupBy, groupByEach, groupByUniqueKey, injectInto, injectInto, injectInto, injectInto, injectInto, max, max, maxBy, min, min, minBy, noneSatisfy, noneSatisfyWith, reject, rejectWith, select, selectWith, sumOfDouble, sumOfFloat, sumOfInt, sumOfLong, toBag, toBiMap, toList, toMap, toSet, toSortedBag, toSortedBag, toSortedBagBy, toSortedListBy, toSortedMap, toSortedMap, toSortedMapBy, toSortedSet, toSortedSet, toSortedSetBy, toString, zip, zipWithIndexMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.eclipse.collections.api.InternalIterable
forEach, forEachWith, forEachWithIndexMethods inherited from interface java.lang.Iterable
iterator, spliteratorMethods inherited from interface org.eclipse.collections.api.LazyIterable
flatCollectWith, toArray, toArray, toImmutableBag, toImmutableList, toImmutableSetMethods inherited from interface org.eclipse.collections.api.RichIterable
aggregateBy, aggregateBy, aggregateInPlaceBy, allSatisfy, allSatisfyWith, anySatisfy, anySatisfyWith, appendString, appendString, appendString, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectIf, collectInt, collectLong, collectShort, collectWith, contains, containsAll, containsAllArguments, containsAllIterable, containsAny, containsAnyIterable, containsBy, containsNone, containsNoneIterable, count, countBy, countBy, countByEach, countByEach, countByWith, countByWith, countWith, detect, detectIfNone, detectOptional, detectWith, detectWithIfNone, detectWithOptional, each, flatCollect, flatCollectBoolean, flatCollectByte, flatCollectChar, flatCollectDouble, flatCollectFloat, flatCollectInt, flatCollectLong, flatCollectShort, flatCollectWith, forEach, getAny, groupBy, groupByAndCollect, groupByEach, groupByUniqueKey, injectInto, injectInto, injectInto, injectInto, injectInto, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, makeString, makeString, makeString, makeString, max, max, maxBy, min, min, minBy, noneSatisfy, noneSatisfyWith, notEmpty, reduce, reduceBy, reduceBy, reduceInPlace, reduceInPlace, reject, rejectWith, select, selectWith, summarizeDouble, summarizeFloat, summarizeInt, summarizeLong, sumOfDouble, sumOfFloat, sumOfInt, sumOfLong, toBag, toBiMap, toImmutableBiMap, toImmutableMap, toImmutableSortedBag, toImmutableSortedBag, toImmutableSortedBagBy, toImmutableSortedList, toImmutableSortedList, toImmutableSortedListBy, toImmutableSortedSet, toImmutableSortedSet, toImmutableSortedSetBy, toList, toMap, toMap, toSet, toSortedBag, toSortedBag, toSortedBagBy, toSortedList, toSortedList, toSortedListBy, toSortedMap, toSortedMap, toSortedMapBy, toSortedSet, toSortedSet, toSortedSetBy, toString, zip, zipWithIndex
-
Constructor Details
-
AbstractLazyIterable
public AbstractLazyIterable()
-
-
Method Details
-
asLazy
- Specified by:
asLazyin interfaceRichIterable<T>- Overrides:
asLazyin classAbstractRichIterable<T>
-
into
- Specified by:
intoin interfaceLazyIterable<T>- Specified by:
intoin interfaceRichIterable<T>- Overrides:
intoin classAbstractRichIterable<T>
-
size
public int size()- Specified by:
sizein interfaceRichIterable<T>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmptyin interfaceRichIterable<T>- Overrides:
isEmptyin classAbstractRichIterable<T>
-
getFirst
- Specified by:
getFirstin interfaceLazyIterable<T>- Specified by:
getFirstin interfaceRichIterable<T>
-
getLast
- Specified by:
getLastin interfaceRichIterable<T>
-
getOnly
- Specified by:
getOnlyin interfaceRichIterable<T>
-
select
- Specified by:
selectin interfaceLazyIterable<T>- Specified by:
selectin interfaceRichIterable<T>
-
selectWith
- Specified by:
selectWithin interfaceLazyIterable<T>- Specified by:
selectWithin interfaceRichIterable<T>
-
reject
- Specified by:
rejectin interfaceLazyIterable<T>- Specified by:
rejectin interfaceRichIterable<T>
-
rejectWith
- Specified by:
rejectWithin interfaceLazyIterable<T>- Specified by:
rejectWithin interfaceRichIterable<T>
-
partition
- Specified by:
partitionin interfaceRichIterable<T>
-
partitionWith
public <P> PartitionMutableList<T> partitionWith(Predicate2<? super T, ? super P> predicate, P parameter) - Specified by:
partitionWithin interfaceRichIterable<T>
-
selectInstancesOf
- Specified by:
selectInstancesOfin interfaceLazyIterable<T>- Specified by:
selectInstancesOfin interfaceRichIterable<T>
-
collect
- Specified by:
collectin interfaceLazyIterable<T>- Specified by:
collectin interfaceRichIterable<T>
-
collectBoolean
- Specified by:
collectBooleanin interfaceLazyIterable<T>- Specified by:
collectBooleanin interfaceRichIterable<T>
-
collectByte
- Specified by:
collectBytein interfaceLazyIterable<T>- Specified by:
collectBytein interfaceRichIterable<T>
-
collectChar
- Specified by:
collectCharin interfaceLazyIterable<T>- Specified by:
collectCharin interfaceRichIterable<T>
-
collectDouble
- Specified by:
collectDoublein interfaceLazyIterable<T>- Specified by:
collectDoublein interfaceRichIterable<T>
-
collectFloat
- Specified by:
collectFloatin interfaceLazyIterable<T>- Specified by:
collectFloatin interfaceRichIterable<T>
-
collectInt
- Specified by:
collectIntin interfaceLazyIterable<T>- Specified by:
collectIntin interfaceRichIterable<T>
-
collectLong
- Specified by:
collectLongin interfaceLazyIterable<T>- Specified by:
collectLongin interfaceRichIterable<T>
-
collectShort
- Specified by:
collectShortin interfaceLazyIterable<T>- Specified by:
collectShortin interfaceRichIterable<T>
-
collectWith
public <P,V> LazyIterable<V> collectWith(Function2<? super T, ? super P, ? extends V> function, P parameter) - Specified by:
collectWithin interfaceLazyIterable<T>- Specified by:
collectWithin interfaceRichIterable<T>
-
flatCollect
- Specified by:
flatCollectin interfaceLazyIterable<T>- Specified by:
flatCollectin interfaceRichIterable<T>
-
concatenate
- Specified by:
concatenatein interfaceLazyIterable<T>
-
collectIf
public <V> LazyIterable<V> collectIf(Predicate<? super T> predicate, Function<? super T, ? extends V> function) - Specified by:
collectIfin interfaceLazyIterable<T>- Specified by:
collectIfin interfaceRichIterable<T>
-
take
- Specified by:
takein interfaceLazyIterable<T>
-
drop
- Specified by:
dropin interfaceLazyIterable<T>
-
takeWhile
- Specified by:
takeWhilein interfaceLazyIterable<T>
-
dropWhile
- Specified by:
dropWhilein interfaceLazyIterable<T>
-
distinct
- Specified by:
distinctin interfaceLazyIterable<T>
-
toStack
-
groupBy
- Specified by:
groupByin interfaceRichIterable<T>
-
groupByEach
- Specified by:
groupByEachin interfaceRichIterable<T>
-
groupByUniqueKey
- Specified by:
groupByUniqueKeyin interfaceRichIterable<T>
-
zip
- Specified by:
zipin interfaceLazyIterable<T>- Specified by:
zipin interfaceRichIterable<T>
-
zipWithIndex
- Specified by:
zipWithIndexin interfaceLazyIterable<T>- Specified by:
zipWithIndexin interfaceRichIterable<T>
-
chunk
- Specified by:
chunkin interfaceLazyIterable<T>- Specified by:
chunkin interfaceRichIterable<T>
-
tap
- Specified by:
tapin interfaceLazyIterable<T>- Specified by:
tapin interfaceRichIterable<T>
-
sumByInt
public <V> ObjectLongMap<V> sumByInt(Function<? super T, ? extends V> groupBy, IntFunction<? super T> function) - Specified by:
sumByIntin interfaceRichIterable<T>
-
sumByFloat
public <V> ObjectDoubleMap<V> sumByFloat(Function<? super T, ? extends V> groupBy, FloatFunction<? super T> function) - Specified by:
sumByFloatin interfaceRichIterable<T>
-
sumByLong
public <V> ObjectLongMap<V> sumByLong(Function<? super T, ? extends V> groupBy, LongFunction<? super T> function) - Specified by:
sumByLongin interfaceRichIterable<T>
-
sumByDouble
public <V> ObjectDoubleMap<V> sumByDouble(Function<? super T, ? extends V> groupBy, DoubleFunction<? super T> function) - Specified by:
sumByDoublein interfaceRichIterable<T>
-
minOptional
- Specified by:
minOptionalin interfaceRichIterable<T>
-
maxOptional
- Specified by:
maxOptionalin interfaceRichIterable<T>
-
minOptional
- Specified by:
minOptionalin interfaceRichIterable<T>
-
maxOptional
- Specified by:
maxOptionalin interfaceRichIterable<T>
-
minByOptional
public <V extends Comparable<? super V>> Optional<T> minByOptional(Function<? super T, ? extends V> function) - Specified by:
minByOptionalin interfaceRichIterable<T>
-
maxByOptional
public <V extends Comparable<? super V>> Optional<T> maxByOptional(Function<? super T, ? extends V> function) - Specified by:
maxByOptionalin interfaceRichIterable<T>
-