Interface MutableByteList
-
- All Superinterfaces:
ByteIterable,ByteList,MutableByteCollection,OrderedByteIterable,PrimitiveIterable,ReversibleByteIterable
public interface MutableByteList extends MutableByteCollection, ByteList
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 booleanaddAllAtIndex(int index, byte... source)booleanaddAllAtIndex(int index, ByteIterable source)voidaddAtIndex(int index, byte element)MutableByteListasSynchronized()MutableByteListasUnmodifiable()MutableList<Byte>boxed()<V> MutableList<V>collect(ByteToObjectFunction<? 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(ByteIntToObjectFunction<? extends V> function)Returns a new MutableList using results obtained by applying the specified function to each element and its corresponding index.MutableByteListdistinct()default MutableByteListnewEmpty()Creates a new empty mutable version of the same List type.MutableByteListreject(BytePredicate predicate)Returns a new ByteIterable with all of the elements in the ByteIterable that return false for the specified predicate.default MutableByteListrejectWithIndex(ByteIntPredicate predicate)Returns a new MutableByteList excluding all elements with corresponding indexes matching the specified predicate.byteremoveAtIndex(int index)MutableByteListreverseThis()MutableByteListselect(BytePredicate predicate)Returns a new ByteIterable with all of the elements in the ByteIterable that return true for the specified predicate.default MutableByteListselectWithIndex(ByteIntPredicate predicate)Returns a new MutableByteList including all elements with corresponding indexes matching the specified predicate.byteset(int index, byte element)default MutableByteListshuffleThis()Randomly permutes this list mutating its contents and returns the same list (this).default MutableByteListshuffleThis(Random rnd)Randomly permutes this list mutating its contents and returns the same list (this).MutableByteListsortThis()Sorts this list mutating its contents and returns the same mutable list (this).default MutableByteListsortThis(ByteComparator comparator)Sorts the internal data structure of this list and returns the list itself as a convenience.default <T> MutableByteListsortThisBy(ByteToObjectFunction<T> function)Sorts the internal data structure of this list based on the natural order of the key returned byfunction.default <T> MutableByteListsortThisBy(ByteToObjectFunction<T> function, Comparator<? super T> comparator)Sorts the internal data structure of this list based on the key returned byfunctionusing the providedcomparator.MutableByteListsubList(int fromIndex, int toIndex)default voidswap(int index1, int index2)default MutableByteListtap(ByteProcedure procedure)ImmutableByteListtoImmutable()Returns an immutable copy of this list.MutableByteListtoReversed()MutableByteListwith(byte element)MutableByteListwithAll(ByteIterable elements)MutableByteListwithout(byte element)MutableByteListwithoutAll(ByteIterable elements)default <T> MutableList<ByteObjectPair<T>>zip(Iterable<T> list)Returns aMutableListformed from thisMutableByteListand aListIterableby combining corresponding elements in pairs.default MutableList<ByteBytePair>zipByte(ByteIterable iterable)Returns aMutableListformed from thisMutableByteListand anotherByteListby combining corresponding elements in pairs.-
Methods inherited from interface org.eclipse.collections.api.ByteIterable
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.ByteList
binarySearch, dotProduct, equals, forEachInBoth, get, hashCode, lastIndexOf
-
Methods inherited from interface org.eclipse.collections.api.collection.primitive.MutableByteCollection
add, addAll, addAll, byteIterator, clear, remove, removeAll, removeAll, removeIf, retainAll, retainAll
-
Methods inherited from interface org.eclipse.collections.api.ordered.primitive.OrderedByteIterable
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.ReversibleByteIterable
asReversed, getLast, injectIntoWithIndex
-
-
-
-
Method Detail
-
addAtIndex
void addAtIndex(int index, byte element)
-
addAllAtIndex
boolean addAllAtIndex(int index, byte... source)
-
addAllAtIndex
boolean addAllAtIndex(int index, ByteIterable source)
-
removeAtIndex
byte removeAtIndex(int index)
-
set
byte set(int index, byte element)
-
boxed
MutableList<Byte> boxed()
-
swap
default void swap(int index1, int index2)
-
select
MutableByteList select(BytePredicate predicate)
Description copied from interface:ByteIterableReturns a new ByteIterable with all of the elements in the ByteIterable that return true for the specified predicate.- Specified by:
selectin interfaceByteIterable- Specified by:
selectin interfaceByteList- Specified by:
selectin interfaceMutableByteCollection- Specified by:
selectin interfaceOrderedByteIterable- Specified by:
selectin interfaceReversibleByteIterable
-
reject
MutableByteList reject(BytePredicate predicate)
Description copied from interface:ByteIterableReturns a new ByteIterable with all of the elements in the ByteIterable that return false for the specified predicate.- Specified by:
rejectin interfaceByteIterable- Specified by:
rejectin interfaceByteList- Specified by:
rejectin interfaceMutableByteCollection- Specified by:
rejectin interfaceOrderedByteIterable- Specified by:
rejectin interfaceReversibleByteIterable
-
with
MutableByteList with(byte element)
- Specified by:
within interfaceMutableByteCollection
-
without
MutableByteList without(byte element)
- Specified by:
withoutin interfaceMutableByteCollection
-
withAll
MutableByteList withAll(ByteIterable elements)
- Specified by:
withAllin interfaceMutableByteCollection
-
withoutAll
MutableByteList withoutAll(ByteIterable elements)
- Specified by:
withoutAllin interfaceMutableByteCollection
-
tap
default MutableByteList tap(ByteProcedure procedure)
- Specified by:
tapin interfaceByteIterable- Specified by:
tapin interfaceByteList- Specified by:
tapin interfaceMutableByteCollection- Since:
- 9.0.
-
selectWithIndex
default MutableByteList selectWithIndex(ByteIntPredicate predicate)
Returns a new MutableByteList including all elements with corresponding indexes matching the specified predicate.- Specified by:
selectWithIndexin interfaceByteList- Specified by:
selectWithIndexin interfaceOrderedByteIterable- Specified by:
selectWithIndexin interfaceReversibleByteIterable- Since:
- 11.1.
-
rejectWithIndex
default MutableByteList rejectWithIndex(ByteIntPredicate predicate)
Returns a new MutableByteList excluding all elements with corresponding indexes matching the specified predicate.- Specified by:
rejectWithIndexin interfaceByteList- Specified by:
rejectWithIndexin interfaceOrderedByteIterable- Specified by:
rejectWithIndexin interfaceReversibleByteIterable- Since:
- 11.1.
-
collect
<V> MutableList<V> collect(ByteToObjectFunction<? extends V> function)
Description copied from interface:ByteIterableReturns 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:
collectin interfaceByteIterable- Specified by:
collectin interfaceByteList- Specified by:
collectin interfaceMutableByteCollection- Specified by:
collectin interfaceOrderedByteIterable- Specified by:
collectin interfaceReversibleByteIterable
-
collectWithIndex
default <V> MutableList<V> collectWithIndex(ByteIntToObjectFunction<? extends V> function)
Returns a new MutableList using results obtained by applying the specified function to each element and its corresponding index.- Specified by:
collectWithIndexin interfaceByteList- Specified by:
collectWithIndexin interfaceOrderedByteIterable- Specified by:
collectWithIndexin interfaceReversibleByteIterable- Since:
- 9.1.
-
reverseThis
MutableByteList reverseThis()
-
toReversed
MutableByteList toReversed()
- Specified by:
toReversedin interfaceByteList- Specified by:
toReversedin interfaceReversibleByteIterable
-
distinct
MutableByteList distinct()
- Specified by:
distinctin interfaceByteList- Specified by:
distinctin interfaceReversibleByteIterable- Since:
- 6.0.
-
sortThis
MutableByteList sortThis()
Sorts this list mutating its contents and returns the same mutable list (this).
-
sortThis
default MutableByteList sortThis(ByteComparator comparator)
Sorts the internal data structure of this list and returns the list itself as a convenience.
-
sortThisBy
default <T> MutableByteList sortThisBy(ByteToObjectFunction<T> function)
Sorts the internal data structure of this list based on the natural order of the key returned byfunction.
-
sortThisBy
default <T> MutableByteList sortThisBy(ByteToObjectFunction<T> function, Comparator<? super T> comparator)
Sorts the internal data structure of this list based on the key returned byfunctionusing the providedcomparator.
-
shuffleThis
default MutableByteList shuffleThis()
Randomly permutes this list mutating its contents and returns the same list (this). Usesjava.util.Randomas the source of randomness.
-
shuffleThis
default MutableByteList shuffleThis(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
MutableByteList asUnmodifiable()
- Specified by:
asUnmodifiablein interfaceMutableByteCollection
-
asSynchronized
MutableByteList asSynchronized()
- Specified by:
asSynchronizedin interfaceMutableByteCollection
-
toImmutable
ImmutableByteList toImmutable()
Returns an immutable copy of this list.- Specified by:
toImmutablein interfaceByteList- Specified by:
toImmutablein interfaceMutableByteCollection
-
subList
MutableByteList subList(int fromIndex, int toIndex)
- Specified by:
subListin interfaceByteList- See Also:
List.subList(int fromIndex, int toIndex)
-
zipByte
default MutableList<ByteBytePair> zipByte(ByteIterable iterable)
Returns aMutableListformed from thisMutableByteListand anotherByteListby combining corresponding elements in pairs. If one of the twoByteLists is longer than the other, its remaining elements are ignored.
-
zip
default <T> MutableList<ByteObjectPair<T>> zip(Iterable<T> list)
Returns aMutableListformed from thisMutableByteListand aListIterableby combining corresponding elements in pairs. If one of the two Lists is longer than the other, its remaining elements are ignored.
-
newEmpty
default MutableByteList newEmpty()
Creates a new empty mutable version of the same List type.- Specified by:
newEmptyin interfaceMutableByteCollection- Since:
- 9.2.
-
-