public final class ListAdapter<T> extends AbstractListAdapter<T> implements Serializable
To create a new wrapper around an existing List instance, use the adapt(List) factory method.
| Modifier and Type | Method and Description |
|---|---|
static <E> MutableList<E> |
adapt(List<E> list) |
boolean |
allSatisfy(Predicate<? super T> predicate) |
boolean |
anySatisfy(Predicate<? super T> predicate) |
ParallelListIterable<T> |
asParallel(ExecutorService executorService,
int batchSize) |
MutableList<T> |
asSynchronized() |
MutableList<T> |
asUnmodifiable() |
MutableList<T> |
clone() |
<S> boolean |
corresponds(OrderedIterable<S> other,
Predicate2<? super T,? super S> predicate) |
int |
count(Predicate<? super T> predicate) |
T |
detect(Predicate<? super T> predicate) |
T |
detectIfNone(Predicate<? super T> predicate,
Function0<? extends T> function) |
int |
detectIndex(Predicate<? super T> predicate) |
int |
detectLastIndex(Predicate<? super T> predicate) |
MutableList<T> |
distinct() |
MutableList<T> |
distinct(HashingStrategy<? super T> hashingStrategy) |
MutableList<T> |
drop(int count) |
MutableList<T> |
dropWhile(Predicate<? super T> predicate) |
void |
each(Procedure<? super T> procedure) |
void |
forEach(int fromIndex,
int toIndex,
Procedure<? super T> procedure) |
void |
forEachWithIndex(int fromIndex,
int toIndex,
ObjectIntProcedure<? super T> objectIntProcedure) |
void |
forEachWithIndex(ObjectIntProcedure<? super T> objectIntProcedure) |
<IV> IV |
injectInto(IV injectedValue,
Function2<? super IV,? super T,? extends IV> function) |
MutableList<T> |
newEmpty()
Deprecated.
use
FastList.newList() instead (inlineable) |
boolean |
noneSatisfy(Predicate<? super T> predicate) |
PartitionMutableList<T> |
partitionWhile(Predicate<? super T> predicate) |
void |
reverseForEach(Procedure<? super T> procedure) |
void |
reverseForEachWithIndex(ObjectIntProcedure<? super T> procedure) |
<S> MutableList<S> |
selectInstancesOf(Class<S> clazz) |
void |
sort(Comparator<? super T> comparator) |
ListAdapter<T> |
sortThis() |
ListAdapter<T> |
sortThis(Comparator<? super T> comparator) |
MutableList<T> |
take(int count) |
MutableList<T> |
takeWhile(Predicate<? super T> predicate) |
ImmutableList<T> |
toImmutable() |
ListAdapter<T> |
with(T... elements) |
ListAdapter<T> |
with(T element) |
ListAdapter<T> |
with(T element1,
T element2) |
ListAdapter<T> |
with(T element1,
T element2,
T element3) |
ListAdapter<T> |
withAll(Iterable<? extends T> elements) |
ListAdapter<T> |
without(T element) |
ListAdapter<T> |
withoutAll(Iterable<? extends T> elements) |
add, addAll, asReversed, collect, collectIf, collectWith, distinctBy, equals, flatCollect, get, groupBy, groupByEach, hashCode, indexOf, lastIndexOf, listIterator, listIterator, partition, partitionWith, reject, rejectWith, remove, select, selectWith, set, sortThisByBoolean, sortThisByByte, sortThisByChar, sortThisByDouble, sortThisByFloat, sortThisByInt, sortThisByLong, sortThisByShort, subList, tap, toStack, zip, zipWithIndexadd, addAll, addAllIterable, allSatisfyWith, anySatisfyWith, appendString, asLazy, chunk, clear, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectIf, collectInt, collectLong, collectShort, collectWith, contains, containsAll, containsAllArguments, containsAllIterable, countWith, detectOptional, detectWith, detectWithIfNone, detectWithOptional, flatCollect, forEachWith, getFirst, getLast, getOnly, groupBy, groupByEach, groupByUniqueKey, groupByUniqueKey, injectInto, injectInto, injectInto, injectInto, injectIntoWith, into, isEmpty, iterator, max, max, maxBy, min, min, minBy, noneSatisfyWith, notEmpty, reject, rejectWith, remove, removeAll, removeAllIterable, removeIf, removeIfWith, retainAll, retainAllIterable, select, selectAndRejectWith, selectWith, size, sumByDouble, sumByFloat, sumByInt, sumByLong, sumOfDouble, sumOfFloat, sumOfInt, sumOfLong, toArray, toArray, toBag, toBiMap, toList, toMap, toMap, toSet, toSortedBag, toSortedBag, toSortedList, toSortedMap, toSortedMap, toSortedSet, toSortedSet, toString, zip, zipWithIndexcollectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, collectWithIndex, flatCollectWith, rejectWithIndex, reverseThis, selectWithIndex, shuffleThis, shuffleThis, sortThisBy, toImmutableList, toReversedaddAllIterable, aggregateBy, aggregateInPlaceBy, countBy, countByEach, countByWith, groupByUniqueKey, injectIntoWith, removeAllIterable, removeIf, removeIfWith, retainAllIterable, selectAndRejectWith, sumByDouble, sumByFloat, sumByInt, sumByLongadd, addAll, clear, contains, containsAll, isEmpty, iterator, remove, removeAll, replaceAll, retainAll, size, spliterator, toArray, toArrayparallelStream, removeIf, streambinarySearch, binarySearch, forEachInBoth, getFirst, getLastcollectWithIndex, getFirstOptional, getLastOptional, rejectWithIndex, selectWithIndexaggregateBy, allSatisfyWith, 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, countBy, countByEach, countByWith, countWith, detectOptional, detectWith, detectWithIfNone, detectWithOptional, flatCollect, flatCollectBoolean, flatCollectByte, flatCollectChar, flatCollectDouble, flatCollectFloat, flatCollectInt, flatCollectLong, flatCollectShort, flatCollectWith, getAny, getOnly, groupBy, groupByAndCollect, groupByEach, groupByUniqueKey, injectInto, injectInto, injectInto, injectInto, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, into, isEmpty, makeString, makeString, makeString, makeString, max, maxBy, maxByOptional, maxOptional, maxOptional, min, minBy, minByOptional, minOptional, minOptional, noneSatisfyWith, notEmpty, reduce, reduceInPlace, reduceInPlace, reject, rejectWith, select, selectWith, size, summarizeDouble, summarizeFloat, summarizeInt, summarizeLong, sumOfDouble, sumOfFloat, sumOfInt, sumOfLong, toArray, toArray, toBag, toBiMap, toImmutableBag, toImmutableBiMap, 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, toStringforEachWithpublic static <E> MutableList<E> adapt(List<E> list)
public ImmutableList<T> toImmutable()
toImmutable in interface MutableCollection<T>toImmutable in interface ListIterable<T>toImmutable in interface MutableList<T>public MutableList<T> asUnmodifiable()
asUnmodifiable in interface MutableCollection<T>asUnmodifiable in interface MutableList<T>public MutableList<T> asSynchronized()
asSynchronized in interface MutableCollection<T>asSynchronized in interface MutableList<T>public MutableList<T> clone()
clone in interface MutableList<T>clone in class AbstractListAdapter<T>@Deprecated public MutableList<T> newEmpty()
FastList.newList() instead (inlineable)newEmpty in interface MutableCollection<T>newEmpty in interface MutableList<T>public void each(Procedure<? super T> procedure)
each in interface RichIterable<T>each in class AbstractCollectionAdapter<T>public void reverseForEach(Procedure<? super T> procedure)
reverseForEach in interface ReversibleIterable<T>public void reverseForEachWithIndex(ObjectIntProcedure<? super T> procedure)
reverseForEachWithIndex in interface ReversibleIterable<T>public void forEachWithIndex(ObjectIntProcedure<? super T> objectIntProcedure)
forEachWithIndex in interface InternalIterable<T>forEachWithIndex in interface OrderedIterable<T>forEachWithIndex in class AbstractCollectionAdapter<T>public void forEachWithIndex(int fromIndex,
int toIndex,
ObjectIntProcedure<? super T> objectIntProcedure)
forEachWithIndex in interface OrderedIterable<T>public T detect(Predicate<? super T> predicate)
detect in interface RichIterable<T>detect in class AbstractCollectionAdapter<T>public T detectIfNone(Predicate<? super T> predicate, Function0<? extends T> function)
detectIfNone in interface RichIterable<T>detectIfNone in class AbstractCollectionAdapter<T>public int detectIndex(Predicate<? super T> predicate)
detectIndex in interface OrderedIterable<T>public int detectLastIndex(Predicate<? super T> predicate)
detectLastIndex in interface ReversibleIterable<T>public int count(Predicate<? super T> predicate)
count in interface RichIterable<T>count in class AbstractCollectionAdapter<T>public <S> boolean corresponds(OrderedIterable<S> other, Predicate2<? super T,? super S> predicate)
corresponds in interface OrderedIterable<T>public boolean anySatisfy(Predicate<? super T> predicate)
anySatisfy in interface RichIterable<T>anySatisfy in class AbstractCollectionAdapter<T>public boolean allSatisfy(Predicate<? super T> predicate)
allSatisfy in interface RichIterable<T>allSatisfy in class AbstractCollectionAdapter<T>public boolean noneSatisfy(Predicate<? super T> predicate)
noneSatisfy in interface RichIterable<T>noneSatisfy in class AbstractCollectionAdapter<T>public <IV> IV injectInto(IV injectedValue,
Function2<? super IV,? super T,? extends IV> function)
injectInto in interface RichIterable<T>injectInto in class AbstractCollectionAdapter<T>public void forEach(int fromIndex,
int toIndex,
Procedure<? super T> procedure)
forEach in interface OrderedIterable<T>public void sort(Comparator<? super T> comparator)
public ListAdapter<T> sortThis(Comparator<? super T> comparator)
sortThis in interface MutableList<T>public ListAdapter<T> sortThis()
sortThis in interface MutableList<T>public ListAdapter<T> with(T element)
with in interface MutableCollection<T>with in interface MutableList<T>public ListAdapter<T> with(T element1, T element2)
public ListAdapter<T> with(T element1, T element2, T element3)
public ListAdapter<T> with(T... elements)
public ListAdapter<T> without(T element)
without in interface MutableCollection<T>without in interface MutableList<T>public ListAdapter<T> withAll(Iterable<? extends T> elements)
withAll in interface MutableCollection<T>withAll in interface MutableList<T>public ListAdapter<T> withoutAll(Iterable<? extends T> elements)
withoutAll in interface MutableCollection<T>withoutAll in interface MutableList<T>public <S> MutableList<S> selectInstancesOf(Class<S> clazz)
selectInstancesOf in interface MutableCollection<T>selectInstancesOf in interface ListIterable<T>selectInstancesOf in interface MutableList<T>selectInstancesOf in interface OrderedIterable<T>selectInstancesOf in interface ReversibleIterable<T>selectInstancesOf in interface RichIterable<T>selectInstancesOf in class AbstractListAdapter<T>public MutableList<T> distinct()
distinct in interface ListIterable<T>distinct in interface MutableList<T>distinct in interface OrderedIterable<T>distinct in interface ReversibleIterable<T>public MutableList<T> distinct(HashingStrategy<? super T> hashingStrategy)
distinct in interface ListIterable<T>distinct in interface MutableList<T>public MutableList<T> take(int count)
take in interface ListIterable<T>take in interface MutableList<T>take in interface ReversibleIterable<T>public MutableList<T> takeWhile(Predicate<? super T> predicate)
takeWhile in interface ListIterable<T>takeWhile in interface MutableList<T>takeWhile in interface OrderedIterable<T>takeWhile in interface ReversibleIterable<T>public MutableList<T> drop(int count)
drop in interface ListIterable<T>drop in interface MutableList<T>drop in interface ReversibleIterable<T>public MutableList<T> dropWhile(Predicate<? super T> predicate)
dropWhile in interface ListIterable<T>dropWhile in interface MutableList<T>dropWhile in interface OrderedIterable<T>dropWhile in interface ReversibleIterable<T>public PartitionMutableList<T> partitionWhile(Predicate<? super T> predicate)
partitionWhile in interface ListIterable<T>partitionWhile in interface MutableList<T>partitionWhile in interface OrderedIterable<T>partitionWhile in interface ReversibleIterable<T>public ParallelListIterable<T> asParallel(ExecutorService executorService, int batchSize)
asParallel in interface ListIterable<T>asParallel in class AbstractListAdapter<T>Copyright © 2004–2022. All rights reserved.