Package one.microstream.collections
Class SubList<E>
- java.lang.Object
-
- one.microstream.collections.SubListView<E>
-
- one.microstream.collections.SubListAccessor<E>
-
- one.microstream.collections.SubList<E>
-
- All Implemented Interfaces:
Iterable<E>
,Consumer<E>
,CapacityCarrying
,CapacityExtendable
,ConsolidatableCollection
,ExtendedBag<E>
,ExtendedCollection<E>
,ExtendedList<E>
,ExtendedSequence<E>
,OptimizableCollection
,ReleasingCollection<E>
,Sized
,Truncateable
,Sortable<E>
,SortableProcedure<E>
,XAddGetCollection<E>
,XAddingBag<E>
,XAddingCollection<E>
,XAddingList<E>
,XAddingSequence<E>
,XBag<E>
,XBasicList<E>
,XBasicSequence<E>
,XCollection<E>
,XDecreasingList<E>
,XDecreasingSequence<E>
,XExpandingList<E>
,XExpandingSequence<E>
,XExtendingList<E>
,XExtendingSequence<E>
,XGettingBag<E>
,XGettingCollection<E>
,XGettingList<E>
,XGettingSequence<E>
,XIncreasingList<E>
,XIncreasingSequence<E>
,XIndexIterable<E>
,XInputtingList<E>
,XInputtingSequence<E>
,XInsertingSequence<E>
,XIterable<E>
,XJoinable<E>
,XList<E>
,XOrderingSequence<E>
,XPrependingList<E>
,XPrependingSequence<E>
,XPreputtingList<E>
,XPreputtingSequence<E>
,XProcessingBag<E>
,XProcessingCollection<E>
,XProcessingList<E>
,XProcessingSequence<E>
,XPutGetBag<E>
,XPutGetCollection<E>
,XPutGetList<E>
,XPutGetSequence<E>
,XPuttingBag<E>
,XPuttingCollection<E>
,XPuttingList<E>
,XPuttingSequence<E>
,XRemovingBag<E>
,XRemovingCollection<E>
,XRemovingList<E>
,XRemovingSequence<E>
,XReplacingBag<E>
,XReplacingCollection<E>
,XSequence<E>
,XSettingList<E>
,XSettingSequence<E>
,XSortableSequence<E>
,Processable<E>
,Clearable
,Copyable
public final class SubList<E> extends SubListAccessor<E> implements XList<E>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface one.microstream.typing.Copyable
Copyable.Static
-
Nested classes/interfaces inherited from interface one.microstream.collections.interfaces.ExtendedCollection
ExtendedCollection.Creator<E,C extends ExtendedCollection<E>>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XBag
XBag.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XBasicSequence
XBasicSequence.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XGettingCollection
XGettingCollection.Creator<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XGettingList
XGettingList.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XGettingSequence
XGettingSequence.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XInputtingList
XInputtingList.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XIterable
XIterable.Executor<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XList
XList.Creator<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XProcessingList
XProcessingList.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XProcessingSequence
XProcessingSequence.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XPutGetList
XPutGetList.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XReplacingBag
XReplacingBag.Factory<E>
-
Nested classes/interfaces inherited from interface one.microstream.collections.types.XSettingList
XSettingList.Creator<E>
-
-
Method Summary
Modifier and Type Method Description void
accept(E element)
boolean
add(E e)
SubList<E>
addAll(E... elements)
SubList<E>
addAll(E[] elements, int offset, int length)
SubList<E>
addAll(XGettingCollection<? extends E> elements)
void
clear()
Clears all elements from the collection while leaving the capacity as it is.long
consolidate()
Consolidates the internal storage of this collection by discarding all elements of the internal storage that have become obsolete or otherwise unneeded anymore.SubList<E>
copy()
Creates a true copy of this list which references th same elements in the same order as this list does at the time the method is called.long
currentCapacity()
Returns the current amount of elements this instance can hold before a storage rebuild becomes necessary.SubList<E>
ensureCapacity(long minimalCapacity)
SubList<E>
ensureFreeCapacity(long minimalFreeCapacity)
Ensures that the next minimalFreeCapacity elements can be actually added in a fast way, meaning for example no internal storage rebuild will be necessary.E
fetch()
SubList<E>
fill(long offset, long length, E element)
boolean
input(long index, E element)
long
inputAll(long index, E... elements)
long
inputAll(long index, E[] elements, int offset, int length)
long
inputAll(long index, XGettingCollection<? extends E> elements)
boolean
insert(long index, E element)
long
insertAll(long index, E... elements)
long
insertAll(long index, E[] elements, int offset, int length)
long
insertAll(long index, XGettingCollection<? extends E> elements)
<C extends Consumer<? super E>>
CmoveSelection(C target, long... indices)
<C extends Consumer<? super E>>
CmoveTo(C target, Predicate<? super E> predicate)
boolean
nullAdd()
boolean
nullInput(long index)
boolean
nullInsert(long index)
boolean
nullPrepend()
boolean
nullPreput()
boolean
nullPut()
long
nullRemove()
one.microstream.collections.SubList.OldSubList<E>
old()
long
optimize()
Optimizes the internal storage of this collection and returns the storage size of the collection after the process is complete.E
pick()
E
pinch()
E
pop()
boolean
prepend(E element)
SubList<E>
prependAll(E... elements)
SubList<E>
prependAll(E[] elements, int srcStartIndex, int srcLength)
SubList<E>
prependAll(XGettingCollection<? extends E> elements)
boolean
preput(E element)
SubList<E>
preputAll(E... elements)
SubList<E>
preputAll(E[] elements, int srcStartIndex, int srcLength)
SubList<E>
preputAll(XGettingCollection<? extends E> elements)
<P extends Consumer<? super E>>
Pprocess(P procedure)
boolean
put(E element)
SubList<E>
putAll(E... elements)
SubList<E>
putAll(E[] elements, int offset, int length)
SubList<E>
putAll(XGettingCollection<? extends E> elements)
SubList<E>
range(long fromIndex, long toIndex)
long
remove(E element)
long
removeAll(XGettingCollection<? extends E> elements)
E
removeAt(long index)
long
removeBy(Predicate<? super E> predicate)
long
removeDuplicates()
long
removeDuplicates(Equalator<? super E> equalator)
boolean
removeOne(E element)
SubList<E>
removeRange(long startIndex, long length)
long
removeSelection(long[] indices)
long
retainAll(XGettingCollection<? extends E> elements)
SubList<E>
retainRange(long startIndex, long length)
E
retrieve(E element)
E
retrieveBy(Predicate<? super E> predicate)
SubList<E>
reverse()
SubList<E>
set(long offset, E[] src, int srcIndex, int srcLength)
SubList<E>
set(long offset, XGettingSequence<? extends E> elements, long elementsOffset, long elementsLength)
SubList<E>
setAll(long offset, E... elements)
SubList<E>
shiftBy(long sourceIndex, long distance)
SubList<E>
shiftBy(long sourceIndex, long distance, long length)
SubList<E>
shiftTo(long sourceIndex, long targetIndex)
SubList<E>
shiftTo(long sourceIndex, long targetIndex, long length)
SubList<E>
sort(Comparator<? super E> comparator)
SubList<E>
swap(long indexA, long indexB)
SubList<E>
swap(long indexA, long indexB, long length)
SubList<E>
toReversed()
void
truncate()
Clears (and reinitializes if needed) this collection in the fastest possible way, i.e.-
Methods inherited from class one.microstream.collections.SubListAccessor
replace, replace, replaceAll, replaceOne, replaceOne, set, setFirst, setGet, setLast, substitute, substitute, view
-
Methods inherited from class one.microstream.collections.SubListView
applies, at, contains, containsAll, containsId, containsSearched, copySelection, copyTo, count, countBy, distinct, distinct, equality, equals, equalsContent, except, filterTo, first, get, getEndIndex, hasVolatileElements, immure, indexBy, indexOf, intersect, isEmpty, isFull, isSorted, iterate, iterateIndexed, iterator, join, last, lastIndexBy, lastIndexOf, listIterator, listIterator, max, maximumCapacity, maxIndex, min, minIndex, nullAllowed, nullContained, peek, poll, remainingCapacity, scan, search, seek, size, toArray, toArray, union, view
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface one.microstream.collections.interfaces.CapacityCarrying
isFull, maximumCapacity, remainingCapacity
-
Methods inherited from interface one.microstream.collections.interfaces.CapacityExtendable
currentFreeCapacity
-
Methods inherited from interface one.microstream.collections.interfaces.ExtendedCollection
nullAllowed
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Methods inherited from interface one.microstream.collections.types.XGettingCollection
applies, contains, containsAll, containsId, containsSearched, copyTo, count, countBy, distinct, distinct, equality, equals, equals, equalsContent, except, filterTo, hashCode, hasVolatileElements, intersect, intSize, iterator, join, max, min, nullContained, search, seek, size, toArray, toArray, union
-
Methods inherited from interface one.microstream.collections.types.XGettingList
immure, listIterator, listIterator, view, view
-
Methods inherited from interface one.microstream.collections.types.XGettingSequence
at, copySelection, first, get, hasIndex, indexBy, indexOf, isSorted, last, lastIndexBy, lastIndexOf, maxIndex, minIndex, peek, poll, scan
-
Methods inherited from interface one.microstream.collections.types.XIndexIterable
iterateIndexed
-
Methods inherited from interface one.microstream.collections.types.XProcessingBag
immure, view
-
Methods inherited from interface one.microstream.collections.types.XProcessingSequence
view
-
Methods inherited from interface one.microstream.collections.types.XReplacingBag
replace, replace, replaceAll, replaceOne, replaceOne, substitute
-
Methods inherited from interface one.microstream.collections.types.XReplacingCollection
substitute
-
Methods inherited from interface one.microstream.collections.types.XSettingSequence
set, setFirst, setGet, setLast
-
-
-
-
Method Detail
-
currentCapacity
public final long currentCapacity()
Description copied from interface:CapacityExtendable
Returns the current amount of elements this instance can hold before a storage rebuild becomes necessary.For carrier implementations that don't have a concept of storage rebuilding (like linked list for example) this method returns the same value as
CapacityCarrying.maximumCapacity()
.- Specified by:
currentCapacity
in interfaceCapacityExtendable
- Returns:
- the current capacity of this instance before a rebuild is required.
-
clear
public final void clear()
Description copied from interface:XRemovingCollection
Clears all elements from the collection while leaving the capacity as it is.- Specified by:
clear
in interfaceClearable
- Specified by:
clear
in interfaceXRemovingCollection<E>
-
accept
public final void accept(E element)
-
add
public final boolean add(E e)
- Specified by:
add
in interfaceXAddingCollection<E>
-
addAll
@SafeVarargs public final SubList<E> addAll(E... elements)
- Specified by:
addAll
in interfaceXAddGetCollection<E>
- Specified by:
addAll
in interfaceXAddingBag<E>
- Specified by:
addAll
in interfaceXAddingCollection<E>
- Specified by:
addAll
in interfaceXAddingList<E>
- Specified by:
addAll
in interfaceXAddingSequence<E>
- Specified by:
addAll
in interfaceXBag<E>
- Specified by:
addAll
in interfaceXBasicList<E>
- Specified by:
addAll
in interfaceXBasicSequence<E>
- Specified by:
addAll
in interfaceXCollection<E>
- Specified by:
addAll
in interfaceXExpandingList<E>
- Specified by:
addAll
in interfaceXExpandingSequence<E>
- Specified by:
addAll
in interfaceXExtendingList<E>
- Specified by:
addAll
in interfaceXExtendingSequence<E>
- Specified by:
addAll
in interfaceXIncreasingList<E>
- Specified by:
addAll
in interfaceXIncreasingSequence<E>
- Specified by:
addAll
in interfaceXInputtingList<E>
- Specified by:
addAll
in interfaceXInputtingSequence<E>
- Specified by:
addAll
in interfaceXInsertingSequence<E>
- Specified by:
addAll
in interfaceXList<E>
- Specified by:
addAll
in interfaceXPutGetCollection<E>
- Specified by:
addAll
in interfaceXPutGetList<E>
- Specified by:
addAll
in interfaceXPutGetSequence<E>
- Specified by:
addAll
in interfaceXPuttingBag<E>
- Specified by:
addAll
in interfaceXPuttingList<E>
- Specified by:
addAll
in interfaceXSequence<E>
-
addAll
public final SubList<E> addAll(XGettingCollection<? extends E> elements)
- Specified by:
addAll
in interfaceXAddGetCollection<E>
- Specified by:
addAll
in interfaceXAddingBag<E>
- Specified by:
addAll
in interfaceXAddingCollection<E>
- Specified by:
addAll
in interfaceXAddingList<E>
- Specified by:
addAll
in interfaceXAddingSequence<E>
- Specified by:
addAll
in interfaceXBag<E>
- Specified by:
addAll
in interfaceXBasicList<E>
- Specified by:
addAll
in interfaceXBasicSequence<E>
- Specified by:
addAll
in interfaceXCollection<E>
- Specified by:
addAll
in interfaceXExpandingList<E>
- Specified by:
addAll
in interfaceXExpandingSequence<E>
- Specified by:
addAll
in interfaceXExtendingList<E>
- Specified by:
addAll
in interfaceXExtendingSequence<E>
- Specified by:
addAll
in interfaceXIncreasingList<E>
- Specified by:
addAll
in interfaceXIncreasingSequence<E>
- Specified by:
addAll
in interfaceXInputtingList<E>
- Specified by:
addAll
in interfaceXInputtingSequence<E>
- Specified by:
addAll
in interfaceXInsertingSequence<E>
- Specified by:
addAll
in interfaceXList<E>
- Specified by:
addAll
in interfaceXPutGetCollection<E>
- Specified by:
addAll
in interfaceXPutGetList<E>
- Specified by:
addAll
in interfaceXPutGetSequence<E>
- Specified by:
addAll
in interfaceXPuttingBag<E>
- Specified by:
addAll
in interfaceXPuttingList<E>
- Specified by:
addAll
in interfaceXSequence<E>
-
addAll
public final SubList<E> addAll(E[] elements, int offset, int length)
- Specified by:
addAll
in interfaceXAddGetCollection<E>
- Specified by:
addAll
in interfaceXAddingBag<E>
- Specified by:
addAll
in interfaceXAddingCollection<E>
- Specified by:
addAll
in interfaceXAddingList<E>
- Specified by:
addAll
in interfaceXAddingSequence<E>
- Specified by:
addAll
in interfaceXBag<E>
- Specified by:
addAll
in interfaceXBasicList<E>
- Specified by:
addAll
in interfaceXBasicSequence<E>
- Specified by:
addAll
in interfaceXCollection<E>
- Specified by:
addAll
in interfaceXExpandingList<E>
- Specified by:
addAll
in interfaceXExpandingSequence<E>
- Specified by:
addAll
in interfaceXExtendingList<E>
- Specified by:
addAll
in interfaceXExtendingSequence<E>
- Specified by:
addAll
in interfaceXIncreasingList<E>
- Specified by:
addAll
in interfaceXIncreasingSequence<E>
- Specified by:
addAll
in interfaceXInputtingList<E>
- Specified by:
addAll
in interfaceXInputtingSequence<E>
- Specified by:
addAll
in interfaceXInsertingSequence<E>
- Specified by:
addAll
in interfaceXList<E>
- Specified by:
addAll
in interfaceXPutGetCollection<E>
- Specified by:
addAll
in interfaceXPutGetList<E>
- Specified by:
addAll
in interfaceXPutGetSequence<E>
- Specified by:
addAll
in interfaceXPuttingBag<E>
- Specified by:
addAll
in interfaceXPuttingList<E>
- Specified by:
addAll
in interfaceXSequence<E>
-
nullAdd
public final boolean nullAdd()
- Specified by:
nullAdd
in interfaceXAddingCollection<E>
-
put
public final boolean put(E element)
- Specified by:
put
in interfaceXPuttingCollection<E>
-
putAll
@SafeVarargs public final SubList<E> putAll(E... elements)
- Specified by:
putAll
in interfaceXBag<E>
- Specified by:
putAll
in interfaceXBasicList<E>
- Specified by:
putAll
in interfaceXBasicSequence<E>
- Specified by:
putAll
in interfaceXCollection<E>
- Specified by:
putAll
in interfaceXExpandingList<E>
- Specified by:
putAll
in interfaceXExpandingSequence<E>
- Specified by:
putAll
in interfaceXIncreasingList<E>
- Specified by:
putAll
in interfaceXIncreasingSequence<E>
- Specified by:
putAll
in interfaceXInputtingList<E>
- Specified by:
putAll
in interfaceXInputtingSequence<E>
- Specified by:
putAll
in interfaceXList<E>
- Specified by:
putAll
in interfaceXPutGetCollection<E>
- Specified by:
putAll
in interfaceXPutGetList<E>
- Specified by:
putAll
in interfaceXPutGetSequence<E>
- Specified by:
putAll
in interfaceXPuttingBag<E>
- Specified by:
putAll
in interfaceXPuttingCollection<E>
- Specified by:
putAll
in interfaceXPuttingList<E>
- Specified by:
putAll
in interfaceXPuttingSequence<E>
- Specified by:
putAll
in interfaceXSequence<E>
-
putAll
public final SubList<E> putAll(E[] elements, int offset, int length)
- Specified by:
putAll
in interfaceXBag<E>
- Specified by:
putAll
in interfaceXBasicList<E>
- Specified by:
putAll
in interfaceXBasicSequence<E>
- Specified by:
putAll
in interfaceXCollection<E>
- Specified by:
putAll
in interfaceXExpandingList<E>
- Specified by:
putAll
in interfaceXExpandingSequence<E>
- Specified by:
putAll
in interfaceXIncreasingList<E>
- Specified by:
putAll
in interfaceXIncreasingSequence<E>
- Specified by:
putAll
in interfaceXInputtingList<E>
- Specified by:
putAll
in interfaceXInputtingSequence<E>
- Specified by:
putAll
in interfaceXList<E>
- Specified by:
putAll
in interfaceXPutGetCollection<E>
- Specified by:
putAll
in interfaceXPutGetList<E>
- Specified by:
putAll
in interfaceXPutGetSequence<E>
- Specified by:
putAll
in interfaceXPuttingBag<E>
- Specified by:
putAll
in interfaceXPuttingCollection<E>
- Specified by:
putAll
in interfaceXPuttingList<E>
- Specified by:
putAll
in interfaceXPuttingSequence<E>
- Specified by:
putAll
in interfaceXSequence<E>
-
putAll
public final SubList<E> putAll(XGettingCollection<? extends E> elements)
- Specified by:
putAll
in interfaceXBag<E>
- Specified by:
putAll
in interfaceXBasicList<E>
- Specified by:
putAll
in interfaceXBasicSequence<E>
- Specified by:
putAll
in interfaceXCollection<E>
- Specified by:
putAll
in interfaceXExpandingList<E>
- Specified by:
putAll
in interfaceXExpandingSequence<E>
- Specified by:
putAll
in interfaceXIncreasingList<E>
- Specified by:
putAll
in interfaceXIncreasingSequence<E>
- Specified by:
putAll
in interfaceXInputtingList<E>
- Specified by:
putAll
in interfaceXInputtingSequence<E>
- Specified by:
putAll
in interfaceXList<E>
- Specified by:
putAll
in interfaceXPutGetCollection<E>
- Specified by:
putAll
in interfaceXPutGetList<E>
- Specified by:
putAll
in interfaceXPutGetSequence<E>
- Specified by:
putAll
in interfaceXPuttingBag<E>
- Specified by:
putAll
in interfaceXPuttingCollection<E>
- Specified by:
putAll
in interfaceXPuttingList<E>
- Specified by:
putAll
in interfaceXPuttingSequence<E>
- Specified by:
putAll
in interfaceXSequence<E>
-
nullPut
public final boolean nullPut()
- Specified by:
nullPut
in interfaceXPuttingCollection<E>
-
prepend
public final boolean prepend(E element)
- Specified by:
prepend
in interfaceXPrependingSequence<E>
-
prependAll
@SafeVarargs public final SubList<E> prependAll(E... elements)
- Specified by:
prependAll
in interfaceXExpandingList<E>
- Specified by:
prependAll
in interfaceXExpandingSequence<E>
- Specified by:
prependAll
in interfaceXExtendingList<E>
- Specified by:
prependAll
in interfaceXExtendingSequence<E>
- Specified by:
prependAll
in interfaceXIncreasingList<E>
- Specified by:
prependAll
in interfaceXIncreasingSequence<E>
- Specified by:
prependAll
in interfaceXInputtingList<E>
- Specified by:
prependAll
in interfaceXInputtingSequence<E>
- Specified by:
prependAll
in interfaceXInsertingSequence<E>
- Specified by:
prependAll
in interfaceXList<E>
- Specified by:
prependAll
in interfaceXPrependingList<E>
- Specified by:
prependAll
in interfaceXPrependingSequence<E>
- Specified by:
prependAll
in interfaceXPreputtingList<E>
- Specified by:
prependAll
in interfaceXPreputtingSequence<E>
-
prependAll
public final SubList<E> prependAll(E[] elements, int srcStartIndex, int srcLength)
- Specified by:
prependAll
in interfaceXExpandingList<E>
- Specified by:
prependAll
in interfaceXExpandingSequence<E>
- Specified by:
prependAll
in interfaceXExtendingList<E>
- Specified by:
prependAll
in interfaceXExtendingSequence<E>
- Specified by:
prependAll
in interfaceXIncreasingList<E>
- Specified by:
prependAll
in interfaceXIncreasingSequence<E>
- Specified by:
prependAll
in interfaceXInputtingList<E>
- Specified by:
prependAll
in interfaceXInputtingSequence<E>
- Specified by:
prependAll
in interfaceXInsertingSequence<E>
- Specified by:
prependAll
in interfaceXList<E>
- Specified by:
prependAll
in interfaceXPrependingList<E>
- Specified by:
prependAll
in interfaceXPrependingSequence<E>
- Specified by:
prependAll
in interfaceXPreputtingList<E>
- Specified by:
prependAll
in interfaceXPreputtingSequence<E>
-
prependAll
public final SubList<E> prependAll(XGettingCollection<? extends E> elements)
- Specified by:
prependAll
in interfaceXExpandingList<E>
- Specified by:
prependAll
in interfaceXExpandingSequence<E>
- Specified by:
prependAll
in interfaceXExtendingList<E>
- Specified by:
prependAll
in interfaceXExtendingSequence<E>
- Specified by:
prependAll
in interfaceXIncreasingList<E>
- Specified by:
prependAll
in interfaceXIncreasingSequence<E>
- Specified by:
prependAll
in interfaceXInputtingList<E>
- Specified by:
prependAll
in interfaceXInputtingSequence<E>
- Specified by:
prependAll
in interfaceXInsertingSequence<E>
- Specified by:
prependAll
in interfaceXList<E>
- Specified by:
prependAll
in interfaceXPrependingList<E>
- Specified by:
prependAll
in interfaceXPrependingSequence<E>
- Specified by:
prependAll
in interfaceXPreputtingList<E>
- Specified by:
prependAll
in interfaceXPreputtingSequence<E>
-
nullPrepend
public final boolean nullPrepend()
- Specified by:
nullPrepend
in interfaceXPrependingSequence<E>
-
preput
public final boolean preput(E element)
- Specified by:
preput
in interfaceXPreputtingSequence<E>
-
preputAll
@SafeVarargs public final SubList<E> preputAll(E... elements)
- Specified by:
preputAll
in interfaceXExpandingList<E>
- Specified by:
preputAll
in interfaceXExpandingSequence<E>
- Specified by:
preputAll
in interfaceXIncreasingList<E>
- Specified by:
preputAll
in interfaceXIncreasingSequence<E>
- Specified by:
preputAll
in interfaceXInputtingList<E>
- Specified by:
preputAll
in interfaceXInputtingSequence<E>
- Specified by:
preputAll
in interfaceXList<E>
- Specified by:
preputAll
in interfaceXPreputtingList<E>
- Specified by:
preputAll
in interfaceXPreputtingSequence<E>
-
preputAll
public final SubList<E> preputAll(E[] elements, int srcStartIndex, int srcLength)
- Specified by:
preputAll
in interfaceXExpandingList<E>
- Specified by:
preputAll
in interfaceXExpandingSequence<E>
- Specified by:
preputAll
in interfaceXIncreasingList<E>
- Specified by:
preputAll
in interfaceXIncreasingSequence<E>
- Specified by:
preputAll
in interfaceXInputtingList<E>
- Specified by:
preputAll
in interfaceXInputtingSequence<E>
- Specified by:
preputAll
in interfaceXList<E>
- Specified by:
preputAll
in interfaceXPreputtingList<E>
- Specified by:
preputAll
in interfaceXPreputtingSequence<E>
-
preputAll
public final SubList<E> preputAll(XGettingCollection<? extends E> elements)
- Specified by:
preputAll
in interfaceXExpandingList<E>
- Specified by:
preputAll
in interfaceXExpandingSequence<E>
- Specified by:
preputAll
in interfaceXIncreasingList<E>
- Specified by:
preputAll
in interfaceXIncreasingSequence<E>
- Specified by:
preputAll
in interfaceXInputtingList<E>
- Specified by:
preputAll
in interfaceXInputtingSequence<E>
- Specified by:
preputAll
in interfaceXList<E>
- Specified by:
preputAll
in interfaceXPreputtingList<E>
- Specified by:
preputAll
in interfaceXPreputtingSequence<E>
-
nullPreput
public final boolean nullPreput()
- Specified by:
nullPreput
in interfaceXPreputtingSequence<E>
-
insert
public final boolean insert(long index, E element)
- Specified by:
insert
in interfaceXInsertingSequence<E>
-
insertAll
@SafeVarargs public final long insertAll(long index, E... elements)
- Specified by:
insertAll
in interfaceXInsertingSequence<E>
-
insertAll
public final long insertAll(long index, E[] elements, int offset, int length)
- Specified by:
insertAll
in interfaceXInsertingSequence<E>
-
insertAll
public final long insertAll(long index, XGettingCollection<? extends E> elements)
- Specified by:
insertAll
in interfaceXInsertingSequence<E>
-
nullInsert
public final boolean nullInsert(long index)
- Specified by:
nullInsert
in interfaceXInsertingSequence<E>
-
input
public final boolean input(long index, E element)
- Specified by:
input
in interfaceXInputtingSequence<E>
-
inputAll
@SafeVarargs public final long inputAll(long index, E... elements)
- Specified by:
inputAll
in interfaceXInputtingSequence<E>
-
inputAll
public final long inputAll(long index, E[] elements, int offset, int length)
- Specified by:
inputAll
in interfaceXInputtingSequence<E>
-
inputAll
public final long inputAll(long index, XGettingCollection<? extends E> elements)
- Specified by:
inputAll
in interfaceXInputtingSequence<E>
-
nullInput
public final boolean nullInput(long index)
- Specified by:
nullInput
in interfaceXInputtingSequence<E>
-
process
public final <P extends Consumer<? super E>> P process(P procedure)
- Specified by:
process
in interfaceProcessable<E>
-
removeDuplicates
public final long removeDuplicates(Equalator<? super E> equalator)
- Specified by:
removeDuplicates
in interfaceXProcessingCollection<E>
-
retrieve
public final E retrieve(E element)
- Specified by:
retrieve
in interfaceXProcessingCollection<E>
-
retrieveBy
public final E retrieveBy(Predicate<? super E> predicate)
- Specified by:
retrieveBy
in interfaceXProcessingCollection<E>
-
removeOne
public final boolean removeOne(E element)
- Specified by:
removeOne
in interfaceXRemovingCollection<E>
-
remove
public final long remove(E element)
- Specified by:
remove
in interfaceXRemovingCollection<E>
-
removeAll
public final long removeAll(XGettingCollection<? extends E> elements)
- Specified by:
removeAll
in interfaceXRemovingCollection<E>
-
removeDuplicates
public final long removeDuplicates()
- Specified by:
removeDuplicates
in interfaceXRemovingCollection<E>
-
retainAll
public final long retainAll(XGettingCollection<? extends E> elements)
- Specified by:
retainAll
in interfaceXRemovingCollection<E>
-
removeBy
public final long removeBy(Predicate<? super E> predicate)
- Specified by:
removeBy
in interfaceXProcessingCollection<E>
-
truncate
public final void truncate()
Description copied from interface:XRemovingCollection
Clears (and reinitializes if needed) this collection in the fastest possible way, i.e. by allocating a new and empty internal storage of default capacity. The collection will be empty after calling this method.- Specified by:
truncate
in interfaceTruncateable
- Specified by:
truncate
in interfaceXRemovingCollection<E>
-
range
public final SubList<E> range(long fromIndex, long toIndex)
- Specified by:
range
in interfaceXDecreasingList<E>
- Specified by:
range
in interfaceXDecreasingSequence<E>
- Specified by:
range
in interfaceXGettingList<E>
- Specified by:
range
in interfaceXGettingSequence<E>
- Specified by:
range
in interfaceXIncreasingList<E>
- Specified by:
range
in interfaceXIncreasingSequence<E>
- Specified by:
range
in interfaceXList<E>
- Specified by:
range
in interfaceXSettingList<E>
- Specified by:
range
in interfaceXSettingSequence<E>
- Overrides:
range
in classSubListAccessor<E>
-
ensureFreeCapacity
public final SubList<E> ensureFreeCapacity(long minimalFreeCapacity)
Description copied from interface:CapacityExtendable
Ensures that the next minimalFreeCapacity elements can be actually added in a fast way, meaning for example no internal storage rebuild will be necessary.- Specified by:
ensureFreeCapacity
in interfaceCapacityExtendable
-
ensureCapacity
public final SubList<E> ensureCapacity(long minimalCapacity)
- Specified by:
ensureCapacity
in interfaceCapacityExtendable
-
consolidate
public final long consolidate()
Description copied from interface:XRemovingCollection
Consolidates the internal storage of this collection by discarding all elements of the internal storage that have become obsolete or otherwise unneeded anymore. (e.g.WeakReference
entries whose reference has been cleared).If this is not possible or not needed in the concrete implementation, this method does nothing and returns 0.
- Specified by:
consolidate
in interfaceConsolidatableCollection
- Specified by:
consolidate
in interfaceXRemovingCollection<E>
- Returns:
- the number of discarded entries.
-
moveTo
public final <C extends Consumer<? super E>> C moveTo(C target, Predicate<? super E> predicate)
- Specified by:
moveTo
in interfaceXProcessingCollection<E>
-
optimize
public final long optimize()
Description copied from interface:OptimizableCollection
Optimizes the internal storage of this collection and returns the storage size of the collection after the process is complete.- Specified by:
optimize
in interfaceOptimizableCollection
- Specified by:
optimize
in interfaceXRemovingCollection<E>
- Returns:
- the storage size of the collection after the optimzation.
-
moveSelection
public final <C extends Consumer<? super E>> C moveSelection(C target, long... indices)
- Specified by:
moveSelection
in interfaceXProcessingSequence<E>
-
removeAt
public final E removeAt(long index) throws UnsupportedOperationException
- Specified by:
removeAt
in interfaceXProcessingSequence<E>
- Throws:
UnsupportedOperationException
-
fetch
public final E fetch()
- Specified by:
fetch
in interfaceXProcessingCollection<E>
-
pop
public final E pop()
- Specified by:
pop
in interfaceXProcessingSequence<E>
-
pinch
public final E pinch()
- Specified by:
pinch
in interfaceXProcessingCollection<E>
-
pick
public final E pick()
- Specified by:
pick
in interfaceXProcessingSequence<E>
-
removeRange
public final SubList<E> removeRange(long startIndex, long length)
- Specified by:
removeRange
in interfaceXRemovingSequence<E>
-
retainRange
public final SubList<E> retainRange(long startIndex, long length)
- Specified by:
retainRange
in interfaceXList<E>
- Specified by:
retainRange
in interfaceXRemovingSequence<E>
-
removeSelection
public final long removeSelection(long[] indices)
- Specified by:
removeSelection
in interfaceXRemovingSequence<E>
-
toReversed
public final SubList<E> toReversed()
- Specified by:
toReversed
in interfaceXBasicList<E>
- Specified by:
toReversed
in interfaceXBasicSequence<E>
- Specified by:
toReversed
in interfaceXDecreasingList<E>
- Specified by:
toReversed
in interfaceXDecreasingSequence<E>
- Specified by:
toReversed
in interfaceXGettingList<E>
- Specified by:
toReversed
in interfaceXGettingSequence<E>
- Specified by:
toReversed
in interfaceXIncreasingList<E>
- Specified by:
toReversed
in interfaceXIncreasingSequence<E>
- Specified by:
toReversed
in interfaceXList<E>
- Specified by:
toReversed
in interfaceXProcessingList<E>
- Specified by:
toReversed
in interfaceXProcessingSequence<E>
- Specified by:
toReversed
in interfaceXPutGetList<E>
- Specified by:
toReversed
in interfaceXPutGetSequence<E>
- Specified by:
toReversed
in interfaceXSequence<E>
- Specified by:
toReversed
in interfaceXSettingList<E>
- Specified by:
toReversed
in interfaceXSettingSequence<E>
- Specified by:
toReversed
in interfaceXSortableSequence<E>
- Overrides:
toReversed
in classSubListAccessor<E>
-
copy
public final SubList<E> copy()
Description copied from interface:XGettingSequence
Creates a true copy of this list which references th same elements in the same order as this list does at the time the method is called. The elements themselves are NOT copied (no deep copying).
The type of the returned list is the same as of this list if possible (i.e.: a SubList can not meaningful return a true copy that references its elements but still is a SubList)- Specified by:
copy
in interfaceCopyable
- Specified by:
copy
in interfaceXAddGetCollection<E>
- Specified by:
copy
in interfaceXBag<E>
- Specified by:
copy
in interfaceXBasicList<E>
- Specified by:
copy
in interfaceXBasicSequence<E>
- Specified by:
copy
in interfaceXCollection<E>
- Specified by:
copy
in interfaceXDecreasingList<E>
- Specified by:
copy
in interfaceXDecreasingSequence<E>
- Specified by:
copy
in interfaceXGettingBag<E>
- Specified by:
copy
in interfaceXGettingCollection<E>
- Specified by:
copy
in interfaceXGettingList<E>
- Specified by:
copy
in interfaceXGettingSequence<E>
- Specified by:
copy
in interfaceXIncreasingList<E>
- Specified by:
copy
in interfaceXIncreasingSequence<E>
- Specified by:
copy
in interfaceXList<E>
- Specified by:
copy
in interfaceXProcessingBag<E>
- Specified by:
copy
in interfaceXProcessingList<E>
- Specified by:
copy
in interfaceXPutGetCollection<E>
- Specified by:
copy
in interfaceXPutGetList<E>
- Specified by:
copy
in interfaceXPutGetSequence<E>
- Specified by:
copy
in interfaceXReplacingBag<E>
- Specified by:
copy
in interfaceXSequence<E>
- Specified by:
copy
in interfaceXSettingList<E>
- Specified by:
copy
in interfaceXSettingSequence<E>
- Specified by:
copy
in interfaceXSortableSequence<E>
- Overrides:
copy
in classSubListAccessor<E>
- Returns:
- a copy of this list
-
nullRemove
public final long nullRemove()
- Specified by:
nullRemove
in interfaceXRemovingCollection<E>
-
sort
public final SubList<E> sort(Comparator<? super E> comparator)
- Specified by:
sort
in interfaceSortable<E>
- Specified by:
sort
in interfaceXDecreasingList<E>
- Specified by:
sort
in interfaceXDecreasingSequence<E>
- Specified by:
sort
in interfaceXIncreasingList<E>
- Specified by:
sort
in interfaceXIncreasingSequence<E>
- Specified by:
sort
in interfaceXList<E>
- Specified by:
sort
in interfaceXSequence<E>
- Specified by:
sort
in interfaceXSettingList<E>
- Specified by:
sort
in interfaceXSettingSequence<E>
- Specified by:
sort
in interfaceXSortableSequence<E>
- Overrides:
sort
in classSubListAccessor<E>
-
swap
public final SubList<E> swap(long indexA, long indexB)
- Specified by:
swap
in interfaceXDecreasingList<E>
- Specified by:
swap
in interfaceXDecreasingSequence<E>
- Specified by:
swap
in interfaceXIncreasingList<E>
- Specified by:
swap
in interfaceXIncreasingSequence<E>
- Specified by:
swap
in interfaceXList<E>
- Specified by:
swap
in interfaceXOrderingSequence<E>
- Specified by:
swap
in interfaceXSettingList<E>
- Specified by:
swap
in interfaceXSettingSequence<E>
- Specified by:
swap
in interfaceXSortableSequence<E>
- Overrides:
swap
in classSubListAccessor<E>
-
swap
public final SubList<E> swap(long indexA, long indexB, long length)
- Specified by:
swap
in interfaceXDecreasingList<E>
- Specified by:
swap
in interfaceXDecreasingSequence<E>
- Specified by:
swap
in interfaceXIncreasingList<E>
- Specified by:
swap
in interfaceXIncreasingSequence<E>
- Specified by:
swap
in interfaceXList<E>
- Specified by:
swap
in interfaceXOrderingSequence<E>
- Specified by:
swap
in interfaceXSettingList<E>
- Specified by:
swap
in interfaceXSettingSequence<E>
- Specified by:
swap
in interfaceXSortableSequence<E>
- Overrides:
swap
in classSubListAccessor<E>
-
setAll
@SafeVarargs public final SubList<E> setAll(long offset, E... elements)
- Specified by:
setAll
in interfaceXDecreasingList<E>
- Specified by:
setAll
in interfaceXDecreasingSequence<E>
- Specified by:
setAll
in interfaceXIncreasingList<E>
- Specified by:
setAll
in interfaceXList<E>
- Specified by:
setAll
in interfaceXSettingList<E>
- Specified by:
setAll
in interfaceXSettingSequence<E>
- Overrides:
setAll
in classSubListAccessor<E>
-
set
public final SubList<E> set(long offset, E[] src, int srcIndex, int srcLength)
- Specified by:
set
in interfaceXDecreasingList<E>
- Specified by:
set
in interfaceXDecreasingSequence<E>
- Specified by:
set
in interfaceXIncreasingList<E>
- Specified by:
set
in interfaceXList<E>
- Specified by:
set
in interfaceXSettingList<E>
- Specified by:
set
in interfaceXSettingSequence<E>
- Overrides:
set
in classSubListAccessor<E>
-
set
public final SubList<E> set(long offset, XGettingSequence<? extends E> elements, long elementsOffset, long elementsLength)
- Specified by:
set
in interfaceXDecreasingList<E>
- Specified by:
set
in interfaceXDecreasingSequence<E>
- Specified by:
set
in interfaceXIncreasingList<E>
- Specified by:
set
in interfaceXList<E>
- Specified by:
set
in interfaceXSettingList<E>
- Specified by:
set
in interfaceXSettingSequence<E>
- Overrides:
set
in classSubListAccessor<E>
-
fill
public final SubList<E> fill(long offset, long length, E element)
- Specified by:
fill
in interfaceXDecreasingList<E>
- Specified by:
fill
in interfaceXIncreasingList<E>
- Specified by:
fill
in interfaceXList<E>
- Specified by:
fill
in interfaceXSettingList<E>
- Overrides:
fill
in classSubListAccessor<E>
-
old
public final one.microstream.collections.SubList.OldSubList<E> old()
- Specified by:
old
in interfaceXGettingCollection<E>
- Specified by:
old
in interfaceXGettingList<E>
- Overrides:
old
in classSubListAccessor<E>
-
reverse
public final SubList<E> reverse()
- Specified by:
reverse
in interfaceXDecreasingList<E>
- Specified by:
reverse
in interfaceXDecreasingSequence<E>
- Specified by:
reverse
in interfaceXIncreasingList<E>
- Specified by:
reverse
in interfaceXIncreasingSequence<E>
- Specified by:
reverse
in interfaceXList<E>
- Specified by:
reverse
in interfaceXOrderingSequence<E>
- Specified by:
reverse
in interfaceXSettingList<E>
- Specified by:
reverse
in interfaceXSettingSequence<E>
- Specified by:
reverse
in interfaceXSortableSequence<E>
- Overrides:
reverse
in classSubListAccessor<E>
-
shiftTo
public final SubList<E> shiftTo(long sourceIndex, long targetIndex)
- Specified by:
shiftTo
in interfaceXList<E>
- Specified by:
shiftTo
in interfaceXOrderingSequence<E>
- Specified by:
shiftTo
in interfaceXSortableSequence<E>
- Overrides:
shiftTo
in classSubListAccessor<E>
-
shiftTo
public final SubList<E> shiftTo(long sourceIndex, long targetIndex, long length)
- Specified by:
shiftTo
in interfaceXList<E>
- Specified by:
shiftTo
in interfaceXOrderingSequence<E>
- Specified by:
shiftTo
in interfaceXSortableSequence<E>
- Overrides:
shiftTo
in classSubListAccessor<E>
-
shiftBy
public final SubList<E> shiftBy(long sourceIndex, long distance)
- Specified by:
shiftBy
in interfaceXList<E>
- Specified by:
shiftBy
in interfaceXOrderingSequence<E>
- Specified by:
shiftBy
in interfaceXSortableSequence<E>
- Overrides:
shiftBy
in classSubListAccessor<E>
-
shiftBy
public final SubList<E> shiftBy(long sourceIndex, long distance, long length)
- Specified by:
shiftBy
in interfaceXList<E>
- Specified by:
shiftBy
in interfaceXOrderingSequence<E>
- Specified by:
shiftBy
in interfaceXSortableSequence<E>
- Overrides:
shiftBy
in classSubListAccessor<E>
-
-