Serializable
, MutableLongCollection
, LongIterable
, PrimitiveIterable
, LongSet
, MutableLongSet
public class SynchronizedLongSet extends AbstractSynchronizedLongCollection implements MutableLongSet
MutableLongSet
. It is imperative that the user manually synchronize on the collection when iterating over it using the
LongIterator
, as per Collections.synchronizedCollection(Collection)
.
This file was automatically generated from template file synchronizedPrimitiveSet.stg.
MutableLongSet.asSynchronized()
,
MutableSet.asSynchronized()
,
Serialized FormConstructor | Description |
---|---|
SynchronizedLongSet(MutableLongSet set) |
|
SynchronizedLongSet(MutableLongSet set,
Object newLock) |
Modifier and Type | Method | Description |
---|---|---|
LazyLongIterable |
asLazy() |
Returns a LazyLongIterable adapter wrapping the source LongIterable.
|
MutableLongSet |
asSynchronized() |
|
MutableLongSet |
asUnmodifiable() |
|
<V> MutableSet<V> |
collect(LongToObjectFunction<? extends V> function) |
Returns a new collection with the results of applying the specified function on each element of the source
collection.
|
boolean |
equals(Object otherSet) |
Follows the same general contract as
Set.equals(Object) . |
LongSet |
freeze() |
Returns a frozen copy of this set.
|
int |
hashCode() |
Follows the same general contract as
Set.hashCode() . |
MutableLongSet |
newEmpty() |
Creates a new empty mutable version of the same Set type.
|
static SynchronizedLongSet |
of(MutableLongSet set) |
This method will take a MutableLongSet and wrap it directly in a SynchronizedLongSet.
|
static SynchronizedLongSet |
of(MutableLongSet set,
Object lock) |
This method will take a MutableLongSet and wrap it directly in a SynchronizedLongSet.
|
MutableLongSet |
reject(LongPredicate predicate) |
Returns a new LongIterable with all of the elements in the LongIterable that
return false for the specified predicate.
|
MutableLongSet |
select(LongPredicate predicate) |
Returns a new LongIterable with all of the elements in the LongIterable that
return true for the specified predicate.
|
ImmutableLongSet |
toImmutable() |
Returns an immutable copy of this set.
|
SynchronizedLongSet |
with(long element) |
|
SynchronizedLongSet |
withAll(LongIterable elements) |
|
SynchronizedLongSet |
without(long element) |
|
SynchronizedLongSet |
withoutAll(LongIterable elements) |
add, addAll, addAll, allSatisfy, anySatisfy, appendString, appendString, appendString, average, chunk, clear, contains, containsAll, containsAll, count, detectIfNone, each, forEach, injectInto, isEmpty, longIterator, makeString, makeString, makeString, max, maxIfEmpty, median, min, minIfEmpty, noneSatisfy, notEmpty, reduce, reduceIfEmpty, remove, removeAll, removeAll, removeIf, retainAll, retainAll, size, sum, toArray, toBag, toList, toSet, toSortedArray, toSortedList, toString
allSatisfy, anySatisfy, average, averageIfEmpty, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, count, detectIfNone, each, flatCollect, forEach, injectInto, max, maxIfEmpty, median, medianIfEmpty, min, minIfEmpty, noneSatisfy, reduce, reduceIfEmpty, reject, select, sum, summaryStatistics, toArray, toBag, toList, toSet, toSortedArray, toSortedList
add, addAll, addAll, clear, longIterator, remove, removeAll, removeAll, removeIf, retainAll, retainAll
tap
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size, toString
public SynchronizedLongSet(MutableLongSet set)
public SynchronizedLongSet(MutableLongSet set, Object newLock)
public static SynchronizedLongSet of(MutableLongSet set)
public static SynchronizedLongSet of(MutableLongSet set, Object lock)
public SynchronizedLongSet without(long element)
without
in interface MutableLongCollection
without
in interface MutableLongSet
without
in class AbstractSynchronizedLongCollection
public SynchronizedLongSet with(long element)
with
in interface MutableLongCollection
with
in interface MutableLongSet
with
in class AbstractSynchronizedLongCollection
public SynchronizedLongSet withAll(LongIterable elements)
withAll
in interface MutableLongCollection
withAll
in interface MutableLongSet
withAll
in class AbstractSynchronizedLongCollection
public SynchronizedLongSet withoutAll(LongIterable elements)
withoutAll
in interface MutableLongCollection
withoutAll
in interface MutableLongSet
withoutAll
in class AbstractSynchronizedLongCollection
public MutableLongSet select(LongPredicate predicate)
LongIterable
select
in interface LongIterable
select
in interface LongSet
select
in interface MutableLongCollection
select
in interface MutableLongSet
select
in class AbstractSynchronizedLongCollection
public MutableLongSet reject(LongPredicate predicate)
LongIterable
reject
in interface LongIterable
reject
in interface LongSet
reject
in interface MutableLongCollection
reject
in interface MutableLongSet
reject
in class AbstractSynchronizedLongCollection
public <V> MutableSet<V> collect(LongToObjectFunction<? extends V> function)
LongIterable
collect
in interface LongIterable
collect
in interface LongSet
collect
in interface MutableLongCollection
collect
in interface MutableLongSet
collect
in class AbstractSynchronizedLongCollection
public boolean equals(Object otherSet)
LongSet
Set.equals(Object)
.public int hashCode()
LongSet
Set.hashCode()
.public LazyLongIterable asLazy()
LongIterable
asLazy
in interface LongIterable
asLazy
in class AbstractSynchronizedLongCollection
public MutableLongSet asUnmodifiable()
asUnmodifiable
in interface MutableLongCollection
asUnmodifiable
in interface MutableLongSet
asUnmodifiable
in class AbstractSynchronizedLongCollection
public MutableLongSet asSynchronized()
asSynchronized
in interface MutableLongCollection
asSynchronized
in interface MutableLongSet
asSynchronized
in class AbstractSynchronizedLongCollection
public LongSet freeze()
MutableLongSet
freeze
in interface LongSet
freeze
in interface MutableLongSet
public ImmutableLongSet toImmutable()
MutableLongSet
toImmutable
in interface LongSet
toImmutable
in interface MutableLongCollection
toImmutable
in interface MutableLongSet
toImmutable
in class AbstractSynchronizedLongCollection
public MutableLongSet newEmpty()
MutableLongSet
newEmpty
in interface MutableLongCollection
newEmpty
in interface MutableLongSet
Copyright © 2004–2019. All rights reserved.