Class AbstractSynchronizedMutableCollection<T>
java.lang.Object
org.eclipse.collections.impl.collection.AbstractSynchronizedRichIterable<T>
org.eclipse.collections.impl.collection.mutable.AbstractSynchronizedMutableCollection<T>
- All Implemented Interfaces:
Iterable<T>,Collection<T>,MutableCollection<T>,InternalIterable<T>,RichIterable<T>
- Direct Known Subclasses:
SynchronizedBag,SynchronizedMutableCollection,SynchronizedMutableList,SynchronizedMutableSet,SynchronizedSortedBag,SynchronizedSortedSet
public abstract class AbstractSynchronizedMutableCollection<T>
extends AbstractSynchronizedRichIterable<T>
implements MutableCollection<T>
-
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanaddAll(Collection<? extends T> coll) booleanaddAllIterable(Iterable<? extends T> iterable) <K,V> MutableMap<K, V> aggregateBy(Function<? super T, ? extends K> groupBy, Function0<? extends V> zeroValueFactory, Function2<? super V, ? super T, ? extends V> nonMutatingAggregator) <K,V> MutableMap<K, V> aggregateInPlaceBy(Function<? super T, ? extends K> groupBy, Function0<? extends V> zeroValueFactory, Procedure2<? super V, ? super T> mutatingAggregator) voidclear()<V> MutableCollection<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> MutableCollection<V>collectInt(IntFunction<? super T> intFunction) collectLong(LongFunction<? super T> longFunction) collectShort(ShortFunction<? super T> shortFunction) <P,V> MutableCollection<V> collectWith(Function2<? super T, ? super P, ? extends V> function, P parameter) <V> MutableBag<V><V> MutableBag<V>countByEach(Function<? super T, ? extends Iterable<V>> function) <V,P> MutableBag<V> countByWith(Function2<? super T, ? super P, ? extends V> function, P parameter) <V> MutableCollection<V>flatCollect(Function<? super T, ? extends Iterable<V>> function) <V> MutableMultimap<V,T> <V> MutableMultimap<V,T> groupByEach(Function<? super T, ? extends Iterable<V>> function) <V> MutableMap<V,T> groupByUniqueKey(Function<? super T, ? extends V> function) <IV,P> IV injectIntoWith(IV injectValue, Function3<? super IV, ? super T, ? super P, ? extends IV> function, P parameter) partitionWith(Predicate2<? super T, ? super P> predicate, P parameter) <P> MutableCollection<T>rejectWith(Predicate2<? super T, ? super P> predicate, P parameter) booleanbooleanremoveAll(Collection<?> coll) booleanremoveAllIterable(Iterable<?> iterable) boolean<P> booleanremoveIfWith(Predicate2<? super T, ? super P> predicate, P parameter) booleanretainAll(Collection<?> coll) booleanretainAllIterable(Iterable<?> iterable) <P> Twin<MutableList<T>>selectAndRejectWith(Predicate2<? super T, ? super P> predicate, P parameter) <S> MutableCollection<S>selectInstancesOf(Class<S> clazz) <P> MutableCollection<T>selectWith(Predicate2<? super T, ? super P> predicate, P parameter) <V> MutableObjectDoubleMap<V>sumByDouble(Function<? super T, ? extends V> groupBy, DoubleFunction<? super T> function) <V> MutableObjectDoubleMap<V>sumByFloat(Function<? super T, ? extends V> groupBy, FloatFunction<? super T> function) <V> MutableObjectLongMap<V>sumByInt(Function<? super T, ? extends V> groupBy, IntFunction<? super T> function) <V> MutableObjectLongMap<V>sumByLong(Function<? super T, ? extends V> groupBy, LongFunction<? super T> function) <S> MutableCollection<Pair<T,S>> Methods inherited from class org.eclipse.collections.impl.collection.AbstractSynchronizedRichIterable
allSatisfy, allSatisfyWith, anySatisfy, anySatisfyWith, appendString, appendString, appendString, asLazy, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectIf, collectInt, collectLong, collectShort, collectWith, contains, containsAll, containsAllArguments, containsAllIterable, containsAny, containsAnyIterable, containsNone, containsNoneIterable, count, countBy, countByEach, countByWith, countWith, detect, detectIfNone, detectOptional, detectWith, detectWithIfNone, detectWithOptional, each, equals, flatCollect, flatCollectBoolean, flatCollectByte, flatCollectChar, flatCollectDouble, flatCollectFloat, flatCollectInt, flatCollectLong, flatCollectShort, forEachWith, forEachWithIndex, getFirst, getLast, getOnly, groupBy, groupByEach, groupByUniqueKey, hashCode, injectInto, injectInto, injectInto, injectInto, injectInto, into, isEmpty, iterator, makeString, makeString, makeString, makeString, max, max, maxBy, maxByOptional, maxOptional, maxOptional, min, min, minBy, minByOptional, minOptional, minOptional, noneSatisfy, noneSatisfyWith, notEmpty, reduceBy, reject, rejectWith, select, selectWith, size, sumOfDouble, sumOfFloat, sumOfInt, sumOfLong, toArray, toArray, toBag, toBiMap, toImmutableBag, toImmutableList, toImmutableSet, toImmutableSortedBag, toImmutableSortedBag, toImmutableSortedBagBy, toImmutableSortedList, toImmutableSortedList, toImmutableSortedSet, toImmutableSortedSet, toImmutableSortedSetBy, toList, toMap, toMap, toSet, toSortedBag, toSortedBag, toSortedList, toSortedList, toSortedListBy, toSortedMap, toSortedMap, toSortedMapBy, toSortedSet, toSortedSet, toString, zip, zipWithIndexMethods inherited from interface java.util.Collection
contains, containsAll, equals, hashCode, isEmpty, iterator, parallelStream, removeIf, size, spliterator, stream, toArrayMethods inherited from interface org.eclipse.collections.api.InternalIterable
forEach, forEachWith, forEachWithIndexMethods inherited from interface org.eclipse.collections.api.collection.MutableCollection
asSynchronized, asUnmodifiable, flatCollectWith, newEmpty, toArray, toArray, toImmutable, with, withAll, without, withoutAllMethods inherited from interface org.eclipse.collections.api.RichIterable
aggregateBy, allSatisfy, allSatisfyWith, anySatisfy, anySatisfyWith, appendString, appendString, appendString, asLazy, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectIf, collectInt, collectLong, collectShort, collectWith, contains, containsAll, containsAllArguments, containsAllIterable, containsAny, containsAnyIterable, containsBy, containsNone, containsNoneIterable, count, countBy, countByEach, countByWith, countWith, detect, detectIfNone, detectOptional, detectWith, detectWithIfNone, detectWithOptional, each, flatCollect, flatCollectBoolean, flatCollectByte, flatCollectChar, flatCollectDouble, flatCollectFloat, flatCollectInt, flatCollectLong, flatCollectShort, flatCollectWith, forEach, getAny, getFirst, getLast, getOnly, groupBy, groupByAndCollect, groupByEach, groupByUniqueKey, injectInto, injectInto, injectInto, injectInto, injectInto, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, into, isEmpty, makeString, makeString, makeString, makeString, max, max, maxBy, maxByOptional, maxOptional, maxOptional, min, min, minBy, minByOptional, minOptional, minOptional, noneSatisfy, noneSatisfyWith, notEmpty, reduce, reduceBy, reduceBy, reduceInPlace, reduceInPlace, reject, rejectWith, select, selectWith, size, summarizeDouble, summarizeFloat, summarizeInt, summarizeLong, sumOfDouble, sumOfFloat, sumOfInt, sumOfLong, toBag, toBiMap, toImmutableBag, toImmutableBiMap, toImmutableList, toImmutableMap, toImmutableSet, 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
-
Method Details
-
select
- Specified by:
selectin interfaceMutableCollection<T>- Specified by:
selectin interfaceRichIterable<T>- Overrides:
selectin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
selectInstancesOf
- Specified by:
selectInstancesOfin interfaceMutableCollection<T>- Specified by:
selectInstancesOfin interfaceRichIterable<T>- Overrides:
selectInstancesOfin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
reject
- Specified by:
rejectin interfaceMutableCollection<T>- Specified by:
rejectin interfaceRichIterable<T>- Overrides:
rejectin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
flatCollect
- Specified by:
flatCollectin interfaceMutableCollection<T>- Specified by:
flatCollectin interfaceRichIterable<T>- Overrides:
flatCollectin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collect
- Specified by:
collectin interfaceMutableCollection<T>- Specified by:
collectin interfaceRichIterable<T>- Overrides:
collectin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectWith
public <P,V> MutableCollection<V> collectWith(Function2<? super T, ? super P, ? extends V> function, P parameter) - Specified by:
collectWithin interfaceMutableCollection<T>- Specified by:
collectWithin interfaceRichIterable<T>- Overrides:
collectWithin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectBoolean
- Specified by:
collectBooleanin interfaceMutableCollection<T>- Specified by:
collectBooleanin interfaceRichIterable<T>- Overrides:
collectBooleanin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectByte
- Specified by:
collectBytein interfaceMutableCollection<T>- Specified by:
collectBytein interfaceRichIterable<T>- Overrides:
collectBytein classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectChar
- Specified by:
collectCharin interfaceMutableCollection<T>- Specified by:
collectCharin interfaceRichIterable<T>- Overrides:
collectCharin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectDouble
- Specified by:
collectDoublein interfaceMutableCollection<T>- Specified by:
collectDoublein interfaceRichIterable<T>- Overrides:
collectDoublein classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectFloat
- Specified by:
collectFloatin interfaceMutableCollection<T>- Specified by:
collectFloatin interfaceRichIterable<T>- Overrides:
collectFloatin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectInt
- Specified by:
collectIntin interfaceMutableCollection<T>- Specified by:
collectIntin interfaceRichIterable<T>- Overrides:
collectIntin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectLong
- Specified by:
collectLongin interfaceMutableCollection<T>- Specified by:
collectLongin interfaceRichIterable<T>- Overrides:
collectLongin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectShort
- Specified by:
collectShortin interfaceMutableCollection<T>- Specified by:
collectShortin interfaceRichIterable<T>- Overrides:
collectShortin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
selectWith
- Specified by:
selectWithin interfaceMutableCollection<T>- Specified by:
selectWithin interfaceRichIterable<T>- Overrides:
selectWithin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
rejectWith
- Specified by:
rejectWithin interfaceMutableCollection<T>- Specified by:
rejectWithin interfaceRichIterable<T>- Overrides:
rejectWithin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
collectIf
public <V> MutableCollection<V> collectIf(Predicate<? super T> predicate, Function<? super T, ? extends V> function) - Specified by:
collectIfin interfaceMutableCollection<T>- Specified by:
collectIfin interfaceRichIterable<T>- Overrides:
collectIfin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
tap
- Specified by:
tapin interfaceMutableCollection<T>- Specified by:
tapin interfaceRichIterable<T>- Overrides:
tapin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
zip
- Specified by:
zipin interfaceMutableCollection<T>- Specified by:
zipin interfaceRichIterable<T>- Overrides:
zipin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
zipWithIndex
- Specified by:
zipWithIndexin interfaceMutableCollection<T>- Specified by:
zipWithIndexin interfaceRichIterable<T>- Overrides:
zipWithIndexin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
groupBy
- Specified by:
groupByin interfaceMutableCollection<T>- Specified by:
groupByin interfaceRichIterable<T>- Overrides:
groupByin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
groupByEach
- Specified by:
groupByEachin interfaceMutableCollection<T>- Specified by:
groupByEachin interfaceRichIterable<T>- Overrides:
groupByEachin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
countBy
- Specified by:
countByin interfaceMutableCollection<T>- Specified by:
countByin interfaceRichIterable<T>- Overrides:
countByin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
countByWith
public <V,P> MutableBag<V> countByWith(Function2<? super T, ? super P, ? extends V> function, P parameter) - Specified by:
countByWithin interfaceMutableCollection<T>- Specified by:
countByWithin interfaceRichIterable<T>- Overrides:
countByWithin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
countByEach
- Specified by:
countByEachin interfaceMutableCollection<T>- Specified by:
countByEachin interfaceRichIterable<T>- Overrides:
countByEachin classAbstractSynchronizedRichIterable<T>- Since:
- 10.0.0
-
partition
- Specified by:
partitionin interfaceMutableCollection<T>- Specified by:
partitionin interfaceRichIterable<T>- Overrides:
partitionin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
partitionWith
public <P> PartitionMutableCollection<T> partitionWith(Predicate2<? super T, ? super P> predicate, P parameter) - Specified by:
partitionWithin interfaceMutableCollection<T>- Specified by:
partitionWithin interfaceRichIterable<T>- Overrides:
partitionWithin classAbstractSynchronizedRichIterable<T>- Since:
- 9.0
-
add
- Specified by:
addin interfaceCollection<T>
-
remove
- Specified by:
removein interfaceCollection<T>
-
addAll
- Specified by:
addAllin interfaceCollection<T>
-
removeAll
- Specified by:
removeAllin interfaceCollection<T>
-
retainAll
- Specified by:
retainAllin interfaceCollection<T>
-
clear
public void clear()- Specified by:
clearin interfaceCollection<T>
-
removeIf
- Specified by:
removeIfin interfaceMutableCollection<T>
-
removeIfWith
- Specified by:
removeIfWithin interfaceMutableCollection<T>
-
addAllIterable
- Specified by:
addAllIterablein interfaceMutableCollection<T>
-
removeAllIterable
- Specified by:
removeAllIterablein interfaceMutableCollection<T>
-
retainAllIterable
- Specified by:
retainAllIterablein interfaceMutableCollection<T>
-
selectAndRejectWith
public <P> Twin<MutableList<T>> selectAndRejectWith(Predicate2<? super T, ? super P> predicate, P parameter) - Specified by:
selectAndRejectWithin interfaceMutableCollection<T>
-
injectIntoWith
public <IV,P> IV injectIntoWith(IV injectValue, Function3<? super IV, ? super T, ? super P, ? extends IV> function, P parameter) - Specified by:
injectIntoWithin interfaceMutableCollection<T>
-
groupByUniqueKey
- Specified by:
groupByUniqueKeyin interfaceMutableCollection<T>- Specified by:
groupByUniqueKeyin interfaceRichIterable<T>- Overrides:
groupByUniqueKeyin classAbstractSynchronizedRichIterable<T>
-
aggregateInPlaceBy
public <K,V> MutableMap<K,V> aggregateInPlaceBy(Function<? super T, ? extends K> groupBy, Function0<? extends V> zeroValueFactory, Procedure2<? super V, ? super T> mutatingAggregator) - Specified by:
aggregateInPlaceByin interfaceMutableCollection<T>- Specified by:
aggregateInPlaceByin interfaceRichIterable<T>- Overrides:
aggregateInPlaceByin classAbstractSynchronizedRichIterable<T>
-
aggregateBy
public <K,V> MutableMap<K,V> aggregateBy(Function<? super T, ? extends K> groupBy, Function0<? extends V> zeroValueFactory, Function2<? super V, ? super T, ? extends V> nonMutatingAggregator) - Specified by:
aggregateByin interfaceMutableCollection<T>- Specified by:
aggregateByin interfaceRichIterable<T>- Overrides:
aggregateByin classAbstractSynchronizedRichIterable<T>
-
sumByInt
public <V> MutableObjectLongMap<V> sumByInt(Function<? super T, ? extends V> groupBy, IntFunction<? super T> function) - Specified by:
sumByIntin interfaceMutableCollection<T>- Specified by:
sumByIntin interfaceRichIterable<T>- Overrides:
sumByIntin classAbstractSynchronizedRichIterable<T>
-
sumByFloat
public <V> MutableObjectDoubleMap<V> sumByFloat(Function<? super T, ? extends V> groupBy, FloatFunction<? super T> function) - Specified by:
sumByFloatin interfaceMutableCollection<T>- Specified by:
sumByFloatin interfaceRichIterable<T>- Overrides:
sumByFloatin classAbstractSynchronizedRichIterable<T>
-
sumByLong
public <V> MutableObjectLongMap<V> sumByLong(Function<? super T, ? extends V> groupBy, LongFunction<? super T> function) - Specified by:
sumByLongin interfaceMutableCollection<T>- Specified by:
sumByLongin interfaceRichIterable<T>- Overrides:
sumByLongin classAbstractSynchronizedRichIterable<T>
-
sumByDouble
public <V> MutableObjectDoubleMap<V> sumByDouble(Function<? super T, ? extends V> groupBy, DoubleFunction<? super T> function) - Specified by:
sumByDoublein interfaceMutableCollection<T>- Specified by:
sumByDoublein interfaceRichIterable<T>- Overrides:
sumByDoublein classAbstractSynchronizedRichIterable<T>
-