Interface MutableFloatList
-
- All Superinterfaces:
FloatIterable
,FloatList
,MutableFloatCollection
,OrderedFloatIterable
,PrimitiveIterable
,ReversibleFloatIterable
- All Known Implementing Classes:
FloatArrayList
,SynchronizedFloatList
,UnmodifiableFloatList
public interface MutableFloatList extends MutableFloatCollection, FloatList
This file was automatically generated from template file mutablePrimitiveList.stg.- Since:
- 3.0.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description boolean
addAllAtIndex(int index, float... source)
boolean
addAllAtIndex(int index, FloatIterable source)
void
addAtIndex(int index, float element)
MutableFloatList
asSynchronized()
MutableFloatList
asUnmodifiable()
<V> MutableList<V>
collect(FloatToObjectFunction<? extends V> function)
Returns a new collection with the results of applying the specified function on each element of the source collection.default <V> MutableList<V>
collectWithIndex(FloatIntToObjectFunction<? extends V> function)
Returns a new MutableList using results obtained by applying the specified function to each element and its corresponding index.MutableFloatList
distinct()
default MutableFloatList
newEmpty()
Creates a new empty mutable version of the same List type.MutableFloatList
reject(FloatPredicate predicate)
Returns a new FloatIterable with all of the elements in the FloatIterable that return false for the specified predicate.default MutableFloatList
rejectWithIndex(FloatIntPredicate predicate)
Returns a new MutableFloatList excluding all elements with corresponding indexes matching the specified predicate.float
removeAtIndex(int index)
MutableFloatList
reverseThis()
MutableFloatList
select(FloatPredicate predicate)
Returns a new FloatIterable with all of the elements in the FloatIterable that return true for the specified predicate.default MutableFloatList
selectWithIndex(FloatIntPredicate predicate)
Returns a new MutableFloatList including all elements with corresponding indexes matching the specified predicate.float
set(int index, float element)
default MutableFloatList
shuffleThis()
Randomly permutes this list mutating its contents and returns the same list (this).default MutableFloatList
shuffleThis(java.util.Random rnd)
Randomly permutes this list mutating its contents and returns the same list (this).MutableFloatList
sortThis()
Sorts this list mutating its contents and returns the same mutable list (this).default MutableFloatList
sortThis(FloatComparator comparator)
Sorts the internal data structure of this list and returns the list itself as a convenience.default <T> MutableFloatList
sortThisBy(FloatToObjectFunction<T> function)
Sorts the internal data structure of this list based on the natural order of the key returned byfunction
.default <T> MutableFloatList
sortThisBy(FloatToObjectFunction<T> function, java.util.Comparator<? super T> comparator)
Sorts the internal data structure of this list based on the key returned byfunction
using the providedcomparator
.MutableFloatList
subList(int fromIndex, int toIndex)
default void
swap(int index1, int index2)
default MutableFloatList
tap(FloatProcedure procedure)
ImmutableFloatList
toImmutable()
Returns an immutable copy of this list.MutableFloatList
toReversed()
MutableFloatList
with(float element)
MutableFloatList
withAll(FloatIterable elements)
MutableFloatList
without(float element)
MutableFloatList
withoutAll(FloatIterable elements)
default <T> MutableList<FloatObjectPair<T>>
zip(java.lang.Iterable<T> list)
Returns aMutableList
formed from thisMutableFloatList
and aListIterable
by combining corresponding elements in pairs.default MutableList<FloatFloatPair>
zipFloat(FloatIterable iterable)
Returns aMutableList
formed from thisMutableFloatList
and anotherFloatList
by combining corresponding elements in pairs.-
Methods inherited from interface org.eclipse.collections.api.FloatIterable
allSatisfy, anySatisfy, asLazy, 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.list.primitive.FloatList
binarySearch, dotProduct, equals, forEachInBoth, get, hashCode, lastIndexOf
-
Methods inherited from interface org.eclipse.collections.api.collection.primitive.MutableFloatCollection
add, addAll, addAll, clear, floatIterator, remove, removeAll, removeAll, removeIf, retainAll, retainAll
-
Methods inherited from interface org.eclipse.collections.api.ordered.primitive.OrderedFloatIterable
collectWithIndex, forEachWithIndex, getFirst, indexOf, rejectWithIndex, selectWithIndex
-
Methods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size, toString
-
Methods inherited from interface org.eclipse.collections.api.ordered.primitive.ReversibleFloatIterable
asReversed, getLast, injectIntoWithIndex
-
-
-
-
Method Detail
-
addAtIndex
void addAtIndex(int index, float element)
-
addAllAtIndex
boolean addAllAtIndex(int index, float... source)
-
addAllAtIndex
boolean addAllAtIndex(int index, FloatIterable source)
-
removeAtIndex
float removeAtIndex(int index)
-
set
float set(int index, float element)
-
swap
default void swap(int index1, int index2)
-
select
MutableFloatList select(FloatPredicate predicate)
Description copied from interface:FloatIterable
Returns a new FloatIterable with all of the elements in the FloatIterable that return true for the specified predicate.- Specified by:
select
in interfaceFloatIterable
- Specified by:
select
in interfaceFloatList
- Specified by:
select
in interfaceMutableFloatCollection
- Specified by:
select
in interfaceOrderedFloatIterable
- Specified by:
select
in interfaceReversibleFloatIterable
-
reject
MutableFloatList reject(FloatPredicate predicate)
Description copied from interface:FloatIterable
Returns a new FloatIterable with all of the elements in the FloatIterable that return false for the specified predicate.- Specified by:
reject
in interfaceFloatIterable
- Specified by:
reject
in interfaceFloatList
- Specified by:
reject
in interfaceMutableFloatCollection
- Specified by:
reject
in interfaceOrderedFloatIterable
- Specified by:
reject
in interfaceReversibleFloatIterable
-
with
MutableFloatList with(float element)
- Specified by:
with
in interfaceMutableFloatCollection
-
without
MutableFloatList without(float element)
- Specified by:
without
in interfaceMutableFloatCollection
-
withAll
MutableFloatList withAll(FloatIterable elements)
- Specified by:
withAll
in interfaceMutableFloatCollection
-
withoutAll
MutableFloatList withoutAll(FloatIterable elements)
- Specified by:
withoutAll
in interfaceMutableFloatCollection
-
tap
default MutableFloatList tap(FloatProcedure procedure)
- Specified by:
tap
in interfaceFloatIterable
- Specified by:
tap
in interfaceFloatList
- Specified by:
tap
in interfaceMutableFloatCollection
- Since:
- 9.0.
-
selectWithIndex
default MutableFloatList selectWithIndex(FloatIntPredicate predicate)
Returns a new MutableFloatList including all elements with corresponding indexes matching the specified predicate.- Specified by:
selectWithIndex
in interfaceFloatList
- Specified by:
selectWithIndex
in interfaceOrderedFloatIterable
- Specified by:
selectWithIndex
in interfaceReversibleFloatIterable
- Since:
- 11.1.
-
rejectWithIndex
default MutableFloatList rejectWithIndex(FloatIntPredicate predicate)
Returns a new MutableFloatList excluding all elements with corresponding indexes matching the specified predicate.- Specified by:
rejectWithIndex
in interfaceFloatList
- Specified by:
rejectWithIndex
in interfaceOrderedFloatIterable
- Specified by:
rejectWithIndex
in interfaceReversibleFloatIterable
- Since:
- 11.1.
-
collect
<V> MutableList<V> collect(FloatToObjectFunction<? extends V> function)
Description copied from interface:FloatIterable
Returns a new collection with the results of applying the specified function on each element of the source collection. This method is also commonly called transform or map.- Specified by:
collect
in interfaceFloatIterable
- Specified by:
collect
in interfaceFloatList
- Specified by:
collect
in interfaceMutableFloatCollection
- Specified by:
collect
in interfaceOrderedFloatIterable
- Specified by:
collect
in interfaceReversibleFloatIterable
-
collectWithIndex
default <V> MutableList<V> collectWithIndex(FloatIntToObjectFunction<? extends V> function)
Returns a new MutableList using results obtained by applying the specified function to each element and its corresponding index.- Specified by:
collectWithIndex
in interfaceFloatList
- Specified by:
collectWithIndex
in interfaceOrderedFloatIterable
- Specified by:
collectWithIndex
in interfaceReversibleFloatIterable
- Since:
- 9.1.
-
reverseThis
MutableFloatList reverseThis()
-
toReversed
MutableFloatList toReversed()
- Specified by:
toReversed
in interfaceFloatList
- Specified by:
toReversed
in interfaceReversibleFloatIterable
-
distinct
MutableFloatList distinct()
- Specified by:
distinct
in interfaceFloatList
- Specified by:
distinct
in interfaceReversibleFloatIterable
- Since:
- 6.0.
-
sortThis
MutableFloatList sortThis()
Sorts this list mutating its contents and returns the same mutable list (this).
-
sortThis
default MutableFloatList sortThis(FloatComparator comparator)
Sorts the internal data structure of this list and returns the list itself as a convenience.
-
sortThisBy
default <T> MutableFloatList sortThisBy(FloatToObjectFunction<T> function)
Sorts the internal data structure of this list based on the natural order of the key returned byfunction
.
-
sortThisBy
default <T> MutableFloatList sortThisBy(FloatToObjectFunction<T> function, java.util.Comparator<? super T> comparator)
Sorts the internal data structure of this list based on the key returned byfunction
using the providedcomparator
.
-
shuffleThis
default MutableFloatList shuffleThis()
Randomly permutes this list mutating its contents and returns the same list (this). Usesjava.util.Random
as the source of randomness.
-
shuffleThis
default MutableFloatList shuffleThis(java.util.Random rnd)
Randomly permutes this list mutating its contents and returns the same list (this). Implements the Fisher-Yates shuffle algorithm using the provided source of randomness.
-
asUnmodifiable
MutableFloatList asUnmodifiable()
- Specified by:
asUnmodifiable
in interfaceMutableFloatCollection
-
asSynchronized
MutableFloatList asSynchronized()
- Specified by:
asSynchronized
in interfaceMutableFloatCollection
-
toImmutable
ImmutableFloatList toImmutable()
Returns an immutable copy of this list.- Specified by:
toImmutable
in interfaceFloatList
- Specified by:
toImmutable
in interfaceMutableFloatCollection
-
subList
MutableFloatList subList(int fromIndex, int toIndex)
-
zipFloat
default MutableList<FloatFloatPair> zipFloat(FloatIterable iterable)
Returns aMutableList
formed from thisMutableFloatList
and anotherFloatList
by combining corresponding elements in pairs. If one of the twoFloatList
s is longer than the other, its remaining elements are ignored.
-
zip
default <T> MutableList<FloatObjectPair<T>> zip(java.lang.Iterable<T> list)
Returns aMutableList
formed from thisMutableFloatList
and aListIterable
by combining corresponding elements in pairs. If one of the two Lists is longer than the other, its remaining elements are ignored.
-
newEmpty
default MutableFloatList newEmpty()
Creates a new empty mutable version of the same List type.- Specified by:
newEmpty
in interfaceMutableFloatCollection
- Since:
- 9.2.
-
-