Class SynchronizedLongSet
- java.lang.Object
-
- org.eclipse.collections.impl.collection.mutable.primitive.AbstractSynchronizedLongCollection
-
- org.eclipse.collections.impl.set.mutable.primitive.SynchronizedLongSet
-
- All Implemented Interfaces:
Serializable
,MutableLongCollection
,LongIterable
,PrimitiveIterable
,LongSet
,MutableLongSet
public class SynchronizedLongSet extends AbstractSynchronizedLongCollection implements MutableLongSet
A synchronized view of aMutableLongSet
. It is imperative that the user manually synchronize on the collection when iterating over it using theLongIterator
, as perCollections.synchronizedCollection(Collection)
.This file was automatically generated from template file synchronizedPrimitiveSet.stg.
- Since:
- 3.1.
- See Also:
MutableLongSet.asSynchronized()
,MutableSet.asSynchronized()
, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SynchronizedLongSet(MutableLongSet set)
SynchronizedLongSet(MutableLongSet set, Object newLock)
-
Method Summary
-
Methods inherited from class org.eclipse.collections.impl.collection.mutable.primitive.AbstractSynchronizedLongCollection
add, addAll, addAll, allSatisfy, anySatisfy, appendString, appendString, appendString, average, chunk, clear, contains, containsAll, containsAll, containsAny, containsAny, containsNone, containsNone, count, detectIfNone, each, injectInto, isEmpty, longIterator, makeString, makeString, makeString, max, maxIfEmpty, median, min, minIfEmpty, noneSatisfy, notEmpty, reduce, reduceIfEmpty, remove, removeAll, removeAll, removeIf, retainAll, retainAll, size, sum, toArray, toArray, toBag, toList, toSet, toSortedArray, toSortedList, toString
-
Methods inherited from interface org.eclipse.collections.api.LongIterable
allSatisfy, anySatisfy, average, averageIfEmpty, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, containsAny, containsAny, containsNone, containsNone, count, detectIfNone, each, flatCollect, forEach, injectInto, injectIntoBoolean, injectIntoByte, injectIntoChar, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, injectIntoShort, max, maxIfEmpty, median, medianIfEmpty, min, minIfEmpty, noneSatisfy, reduce, reduceIfEmpty, reject, select, sum, summaryStatistics, toArray, toArray, toBag, toList, toSet, toSortedArray, toSortedList, toSortedList, toSortedListBy, toSortedListBy
-
Methods inherited from interface org.eclipse.collections.api.set.primitive.LongSet
isProperSubsetOf, isSubsetOf
-
Methods inherited from interface org.eclipse.collections.api.collection.primitive.MutableLongCollection
add, addAll, addAll, clear, longIterator, remove, removeAll, removeAll, removeIf, retainAll, retainAll
-
Methods inherited from interface org.eclipse.collections.api.set.primitive.MutableLongSet
difference, intersect, symmetricDifference, tap, union
-
Methods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size, toString
-
-
-
-
Constructor Detail
-
SynchronizedLongSet
public SynchronizedLongSet(MutableLongSet set)
-
SynchronizedLongSet
public SynchronizedLongSet(MutableLongSet set, Object newLock)
-
-
Method Detail
-
of
public static SynchronizedLongSet of(MutableLongSet set)
This method will take a MutableLongSet and wrap it directly in a SynchronizedLongSet.
-
of
public static SynchronizedLongSet of(MutableLongSet set, Object lock)
This method will take a MutableLongSet and wrap it directly in a SynchronizedLongSet. Additionally, a developer specifies which lock to use with the collection.
-
without
public SynchronizedLongSet without(long element)
- Specified by:
without
in interfaceMutableLongCollection
- Specified by:
without
in interfaceMutableLongSet
- Overrides:
without
in classAbstractSynchronizedLongCollection
-
boxed
public MutableSet<Long> boxed()
- Specified by:
boxed
in interfaceMutableLongSet
-
with
public SynchronizedLongSet with(long element)
- Specified by:
with
in interfaceMutableLongCollection
- Specified by:
with
in interfaceMutableLongSet
- Overrides:
with
in classAbstractSynchronizedLongCollection
-
withAll
public SynchronizedLongSet withAll(LongIterable elements)
- Specified by:
withAll
in interfaceMutableLongCollection
- Specified by:
withAll
in interfaceMutableLongSet
- Overrides:
withAll
in classAbstractSynchronizedLongCollection
-
withoutAll
public SynchronizedLongSet withoutAll(LongIterable elements)
- Specified by:
withoutAll
in interfaceMutableLongCollection
- Specified by:
withoutAll
in interfaceMutableLongSet
- Overrides:
withoutAll
in classAbstractSynchronizedLongCollection
-
select
public MutableLongSet select(LongPredicate predicate)
- Specified by:
select
in interfaceLongIterable
- Specified by:
select
in interfaceLongSet
- Specified by:
select
in interfaceMutableLongCollection
- Specified by:
select
in interfaceMutableLongSet
- Overrides:
select
in classAbstractSynchronizedLongCollection
-
reject
public MutableLongSet reject(LongPredicate predicate)
- Specified by:
reject
in interfaceLongIterable
- Specified by:
reject
in interfaceLongSet
- Specified by:
reject
in interfaceMutableLongCollection
- Specified by:
reject
in interfaceMutableLongSet
- Overrides:
reject
in classAbstractSynchronizedLongCollection
-
collect
public <V> MutableSet<V> collect(LongToObjectFunction<? extends V> function)
- Specified by:
collect
in interfaceLongIterable
- Specified by:
collect
in interfaceLongSet
- Specified by:
collect
in interfaceMutableLongCollection
- Specified by:
collect
in interfaceMutableLongSet
- Overrides:
collect
in classAbstractSynchronizedLongCollection
-
cartesianProduct
public LazyIterable<LongLongPair> cartesianProduct(LongSet set)
- Specified by:
cartesianProduct
in interfaceLongSet
-
equals
public boolean equals(Object otherSet)
-
hashCode
public int hashCode()
-
asLazy
public LazyLongIterable asLazy()
- Specified by:
asLazy
in interfaceLongIterable
- Overrides:
asLazy
in classAbstractSynchronizedLongCollection
-
asUnmodifiable
public MutableLongSet asUnmodifiable()
- Specified by:
asUnmodifiable
in interfaceMutableLongCollection
- Specified by:
asUnmodifiable
in interfaceMutableLongSet
- Overrides:
asUnmodifiable
in classAbstractSynchronizedLongCollection
-
asSynchronized
public MutableLongSet asSynchronized()
- Specified by:
asSynchronized
in interfaceMutableLongCollection
- Specified by:
asSynchronized
in interfaceMutableLongSet
- Overrides:
asSynchronized
in classAbstractSynchronizedLongCollection
-
freeze
public LongSet freeze()
- Specified by:
freeze
in interfaceLongSet
- Specified by:
freeze
in interfaceMutableLongSet
-
toImmutable
public ImmutableLongSet toImmutable()
- Specified by:
toImmutable
in interfaceLongSet
- Specified by:
toImmutable
in interfaceMutableLongCollection
- Specified by:
toImmutable
in interfaceMutableLongSet
- Overrides:
toImmutable
in classAbstractSynchronizedLongCollection
-
newEmpty
public MutableLongSet newEmpty()
- Specified by:
newEmpty
in interfaceMutableLongCollection
- Specified by:
newEmpty
in interfaceMutableLongSet
- Since:
- 9.2.
-
-