Serializable
, MutableLongCollection
, LongList
, MutableLongList
, LongIterable
, OrderedLongIterable
, ReversibleLongIterable
, PrimitiveIterable
@ThreadSafe public final class SynchronizedLongList extends AbstractSynchronizedLongCollection implements MutableLongList
MutableLongList
. 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 synchronizedPrimitiveList.stg.
MutableLongList.asSynchronized()
,
MutableList.asSynchronized()
,
Serialized FormConstructor | Description |
---|---|
SynchronizedLongList(MutableLongList list) |
|
SynchronizedLongList(MutableLongList list,
Object newLock) |
Modifier and Type | Method | Description |
---|---|---|
boolean |
addAllAtIndex(int index,
long... source) |
|
boolean |
addAllAtIndex(int index,
LongIterable source) |
|
void |
addAtIndex(int index,
long element) |
|
LazyLongIterable |
asLazy() |
Returns a LazyLongIterable adapter wrapping the source LongIterable.
|
LazyLongIterable |
asReversed() |
|
MutableLongList |
asSynchronized() |
|
MutableLongList |
asUnmodifiable() |
|
int |
binarySearch(long value) |
|
<V> MutableList<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.
|
MutableLongList |
distinct() |
|
long |
dotProduct(LongList list) |
|
boolean |
equals(Object otherList) |
Follows the same general contract as
List.equals(Object) . |
void |
forEachWithIndex(LongIntProcedure procedure) |
|
long |
get(int index) |
|
long |
getFirst() |
|
long |
getLast() |
|
int |
hashCode() |
Follows the same general contract as
List.hashCode() . |
int |
indexOf(long value) |
|
<T> T |
injectIntoWithIndex(T injectedValue,
ObjectLongIntToObjectFunction<? super T,? extends T> function) |
|
int |
lastIndexOf(long value) |
|
MutableLongList |
reject(LongPredicate predicate) |
Returns a new LongIterable with all of the elements in the LongIterable that
return false for the specified predicate.
|
long |
removeAtIndex(int index) |
|
MutableLongList |
reverseThis() |
|
MutableLongList |
select(LongPredicate predicate) |
Returns a new LongIterable with all of the elements in the LongIterable that
return true for the specified predicate.
|
long |
set(int index,
long element) |
|
MutableLongList |
sortThis() |
Sorts this list mutating its contents and returns the same mutable list (this).
|
MutableLongList |
subList(int fromIndex,
int toIndex) |
|
ImmutableLongList |
toImmutable() |
Returns an immutable copy of this list.
|
MutableLongList |
toReversed() |
|
SynchronizedLongList |
with(long element) |
|
SynchronizedLongList |
withAll(LongIterable elements) |
|
SynchronizedLongList |
without(long element) |
|
SynchronizedLongList |
withoutAll(LongIterable elements) |
add, addAll, addAll, allSatisfy, anySatisfy, appendString, appendString, appendString, average, clear, contains, containsAll, containsAll, count, detectIfNone, each, forEach, injectInto, isEmpty, longIterator, makeString, makeString, makeString, max, maxIfEmpty, median, min, minIfEmpty, noneSatisfy, notEmpty, remove, removeAll, removeAll, retainAll, retainAll, size, sum, toArray, toBag, toList, toSet, toSortedArray, toSortedList, toString
allSatisfy, anySatisfy, average, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, count, detectIfNone, each, flatCollect, forEach, injectInto, max, maxIfEmpty, median, min, minIfEmpty, noneSatisfy, reject, select, sum, summaryStatistics, toArray, toBag, toList, toSet, toSortedArray, toSortedList
add, addAll, addAll, clear, longIterator, remove, removeAll, removeAll, retainAll, retainAll
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size, toString
public SynchronizedLongList(MutableLongList list)
public SynchronizedLongList(MutableLongList list, Object newLock)
public long getFirst()
getFirst
in interface OrderedLongIterable
public long getLast()
getLast
in interface ReversibleLongIterable
public int indexOf(long value)
indexOf
in interface OrderedLongIterable
public int lastIndexOf(long value)
lastIndexOf
in interface LongList
public void addAtIndex(int index, long element)
addAtIndex
in interface MutableLongList
public boolean addAllAtIndex(int index, long... source)
addAllAtIndex
in interface MutableLongList
public boolean addAllAtIndex(int index, LongIterable source)
addAllAtIndex
in interface MutableLongList
public long removeAtIndex(int index)
removeAtIndex
in interface MutableLongList
public long set(int index, long element)
set
in interface MutableLongList
public SynchronizedLongList with(long element)
with
in interface MutableLongCollection
with
in interface MutableLongList
with
in class AbstractSynchronizedLongCollection
public SynchronizedLongList without(long element)
without
in interface MutableLongCollection
without
in interface MutableLongList
without
in class AbstractSynchronizedLongCollection
public SynchronizedLongList withAll(LongIterable elements)
withAll
in interface MutableLongCollection
withAll
in interface MutableLongList
withAll
in class AbstractSynchronizedLongCollection
public SynchronizedLongList withoutAll(LongIterable elements)
withoutAll
in interface MutableLongCollection
withoutAll
in interface MutableLongList
withoutAll
in class AbstractSynchronizedLongCollection
public MutableLongList select(LongPredicate predicate)
LongIterable
select
in interface LongIterable
select
in interface LongList
select
in interface MutableLongCollection
select
in interface MutableLongList
select
in interface OrderedLongIterable
select
in interface ReversibleLongIterable
select
in class AbstractSynchronizedLongCollection
public MutableLongList reject(LongPredicate predicate)
LongIterable
reject
in interface LongIterable
reject
in interface LongList
reject
in interface MutableLongCollection
reject
in interface MutableLongList
reject
in interface OrderedLongIterable
reject
in interface ReversibleLongIterable
reject
in class AbstractSynchronizedLongCollection
public <V> MutableList<V> collect(LongToObjectFunction<? extends V> function)
LongIterable
collect
in interface LongIterable
collect
in interface LongList
collect
in interface MutableLongCollection
collect
in interface MutableLongList
collect
in interface OrderedLongIterable
collect
in interface ReversibleLongIterable
collect
in class AbstractSynchronizedLongCollection
public MutableLongList sortThis()
MutableLongList
sortThis
in interface MutableLongList
public int binarySearch(long value)
binarySearch
in interface LongList
public long dotProduct(LongList list)
dotProduct
in interface LongList
public boolean equals(Object otherList)
LongList
List.equals(Object)
.public int hashCode()
LongList
List.hashCode()
.public LazyLongIterable asLazy()
LongIterable
asLazy
in interface LongIterable
asLazy
in class AbstractSynchronizedLongCollection
public MutableLongList asUnmodifiable()
asUnmodifiable
in interface MutableLongCollection
asUnmodifiable
in interface MutableLongList
asUnmodifiable
in class AbstractSynchronizedLongCollection
public MutableLongList asSynchronized()
asSynchronized
in interface MutableLongCollection
asSynchronized
in interface MutableLongList
asSynchronized
in class AbstractSynchronizedLongCollection
public ImmutableLongList toImmutable()
MutableLongList
toImmutable
in interface LongList
toImmutable
in interface MutableLongCollection
toImmutable
in interface MutableLongList
toImmutable
in class AbstractSynchronizedLongCollection
public MutableLongList reverseThis()
reverseThis
in interface MutableLongList
public MutableLongList toReversed()
toReversed
in interface LongList
toReversed
in interface MutableLongList
toReversed
in interface ReversibleLongIterable
public LazyLongIterable asReversed()
asReversed
in interface ReversibleLongIterable
public void forEachWithIndex(LongIntProcedure procedure)
forEachWithIndex
in interface OrderedLongIterable
public <T> T injectIntoWithIndex(T injectedValue, ObjectLongIntToObjectFunction<? super T,? extends T> function)
injectIntoWithIndex
in interface OrderedLongIterable
injectIntoWithIndex
in interface ReversibleLongIterable
public MutableLongList distinct()
distinct
in interface LongList
distinct
in interface MutableLongList
distinct
in interface ReversibleLongIterable
public MutableLongList subList(int fromIndex, int toIndex)
subList
in interface LongList
subList
in interface MutableLongList
Copyright © 2004–2017. All rights reserved.