Class SynchronizedLongIterable
java.lang.Object
org.eclipse.collections.impl.primitive.SynchronizedLongIterable
- All Implemented Interfaces:
Serializable,LongIterable,PrimitiveIterable
A synchronized view of a LongIterable.
This file was automatically generated from template file synchronizedPrimitiveIterable.stg.
- Since:
- 5.0.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbooleanallSatisfy(LongPredicate predicate) booleananySatisfy(LongPredicate predicate) voidappendString(Appendable appendable) voidappendString(Appendable appendable, String separator) voidappendString(Appendable appendable, String start, String separator, String end) asLazy()doubleaverage()chunk(int size) <V> RichIterable<V>collect(LongToObjectFunction<? extends V> function) booleancontains(long value) booleancontainsAll(long... source) booleancontainsAll(LongIterable source) booleancontainsAny(long... source) booleancontainsAny(LongIterable source) booleancontainsNone(long... source) booleancontainsNone(LongIterable source) intcount(LongPredicate predicate) longdetectIfNone(LongPredicate predicate, long ifNone) voideach(LongProcedure procedure) <T> TinjectInto(T injectedValue, ObjectLongToObjectFunction<? super T, ? extends T> function) booleanisEmpty()Must be called in a synchronized block.makeString(String separator) makeString(String start, String separator, String end) longmax()longmaxIfEmpty(long defaultValue) doublemedian()longmin()longminIfEmpty(long defaultValue) booleannoneSatisfy(LongPredicate predicate) booleannotEmpty()static SynchronizedLongIterableof(LongIterable iterable) This method will take a LongIterable and wrap it directly in a SynchronizedLongIterable.static SynchronizedLongIterableof(LongIterable iterable, Object lock) This method will take a LongIterable and wrap it directly in a SynchronizedLongIterable.longreduce(LongLongToLongFunction accumulator) longreduceIfEmpty(LongLongToLongFunction accumulator, long defaultValue) reject(LongPredicate predicate) select(LongPredicate predicate) intsize()longsum()long[]toArray()long[]toArray(long[] target) toBag()toList()toSet()long[]toString()Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.eclipse.collections.api.LongIterable
averageIfEmpty, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, flatCollect, forEach, injectIntoBoolean, injectIntoByte, injectIntoChar, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, injectIntoShort, medianIfEmpty, reject, select, summaryStatistics, tap, toSortedList, toSortedListBy, toSortedListBy
-
Method Details
-
of
This method will take a LongIterable and wrap it directly in a SynchronizedLongIterable. -
of
This method will take a LongIterable and wrap it directly in a SynchronizedLongIterable. Additionally, a developer specifies which lock to use with the collection. -
toArray
public long[] toArray()- Specified by:
toArrayin interfaceLongIterable
-
toArray
public long[] toArray(long[] target) - Specified by:
toArrayin interfaceLongIterable
-
contains
public boolean contains(long value) - Specified by:
containsin interfaceLongIterable
-
containsAll
public boolean containsAll(long... source) - Specified by:
containsAllin interfaceLongIterable
-
containsAll
- Specified by:
containsAllin interfaceLongIterable
-
containsAny
public boolean containsAny(long... source) - Specified by:
containsAnyin interfaceLongIterable
-
containsAny
- Specified by:
containsAnyin interfaceLongIterable
-
containsNone
public boolean containsNone(long... source) - Specified by:
containsNonein interfaceLongIterable
-
containsNone
- Specified by:
containsNonein interfaceLongIterable
-
each
- Specified by:
eachin interfaceLongIterable- Since:
- 7.0.
-
select
- Specified by:
selectin interfaceLongIterable
-
reject
- Specified by:
rejectin interfaceLongIterable
-
collect
- Specified by:
collectin interfaceLongIterable
-
detectIfNone
- Specified by:
detectIfNonein interfaceLongIterable
-
count
- Specified by:
countin interfaceLongIterable
-
anySatisfy
- Specified by:
anySatisfyin interfaceLongIterable
-
allSatisfy
- Specified by:
allSatisfyin interfaceLongIterable
-
noneSatisfy
- Specified by:
noneSatisfyin interfaceLongIterable
-
toList
- Specified by:
toListin interfaceLongIterable
-
toSet
- Specified by:
toSetin interfaceLongIterable
-
toBag
- Specified by:
toBagin interfaceLongIterable
-
asLazy
- Specified by:
asLazyin interfaceLongIterable
-
sum
public long sum()- Specified by:
sumin interfaceLongIterable
-
max
public long max()- Specified by:
maxin interfaceLongIterable
-
maxIfEmpty
public long maxIfEmpty(long defaultValue) - Specified by:
maxIfEmptyin interfaceLongIterable
-
min
public long min()- Specified by:
minin interfaceLongIterable
-
minIfEmpty
public long minIfEmpty(long defaultValue) - Specified by:
minIfEmptyin interfaceLongIterable
-
average
public double average()- Specified by:
averagein interfaceLongIterable
-
median
public double median()- Specified by:
medianin interfaceLongIterable
-
toSortedArray
public long[] toSortedArray()- Specified by:
toSortedArrayin interfaceLongIterable
-
toSortedList
- Specified by:
toSortedListin interfaceLongIterable
-
size
public int size()- Specified by:
sizein interfacePrimitiveIterable
-
isEmpty
public boolean isEmpty()- Specified by:
isEmptyin interfacePrimitiveIterable
-
notEmpty
public boolean notEmpty()- Specified by:
notEmptyin interfacePrimitiveIterable
-
injectInto
public <T> T injectInto(T injectedValue, ObjectLongToObjectFunction<? super T, ? extends T> function) - Specified by:
injectIntoin interfaceLongIterable
-
reduce
- Specified by:
reducein interfaceLongIterable
-
reduceIfEmpty
- Specified by:
reduceIfEmptyin interfaceLongIterable
-
chunk
- Specified by:
chunkin interfaceLongIterable
-
toString
- Specified by:
toStringin interfacePrimitiveIterable- Overrides:
toStringin classObject
-
makeString
- Specified by:
makeStringin interfacePrimitiveIterable
-
makeString
- Specified by:
makeStringin interfacePrimitiveIterable
-
makeString
- Specified by:
makeStringin interfacePrimitiveIterable
-
appendString
- Specified by:
appendStringin interfacePrimitiveIterable
-
appendString
- Specified by:
appendStringin interfacePrimitiveIterable
-
appendString
- Specified by:
appendStringin interfacePrimitiveIterable
-
longIterator
Must be called in a synchronized block.- Specified by:
longIteratorin interfaceLongIterable
-