Package com.illumon.iris.db.v2.utils
Class OrderedKeysAsChunkImpl
java.lang.Object
com.illumon.iris.db.v2.utils.OrderedKeysAsChunkImpl
- All Implemented Interfaces:
LongSizedDataStructure
,OrderedKeys
,SafeCloseable
,AutoCloseable
- Direct Known Subclasses:
CurrentOnlyIndex
,RspOrderedKeys
,ShiftedOrderedKeys
,SingleRangeOrderedKeys
,SortedIndex
,SortedRangesOrderedKeys
public abstract class OrderedKeysAsChunkImpl extends Object implements OrderedKeys
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.illumon.iris.db.v2.utils.OrderedKeys
OrderedKeys.Iterator
-
Field Summary
-
Constructor Summary
Constructors Constructor Description OrderedKeysAsChunkImpl()
-
Method Summary
Modifier and Type Method Description LongChunk<Attributes.OrderedKeyIndices>
asKeyIndicesChunk()
Get aLongChunk
representation of the individual keys in thisOrderedKeys
.LongChunk<Attributes.OrderedKeyRanges>
asKeyRangesChunk()
Get aLongChunk
representation of key ranges in thisOrderedKeys
.void
close()
Free any resources associated with this object.protected void
closeOrderedKeysAsChunkImpl()
protected void
invalidateOrderedKeysAsChunkImpl()
abstract long
lastKey()
Get the last key in thisOrderedKeys
.abstract long
rangesCountUpperBound()
protected long
runsUpperBound()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.illumon.iris.db.v2.utils.OrderedKeys
asIndex, fillKeyIndicesChunk, fillKeyRangesChunk, firstKey, forAllLongRanges, forAllLongs, forEachLong, forEachLongRange, getAverageRunLengthEstimate, getOrderedKeysByKeyRange, getOrderedKeysByPosition, getOrderedKeysIterator, isContiguous, isEmpty, size
-
Constructor Details
-
OrderedKeysAsChunkImpl
public OrderedKeysAsChunkImpl()
-
-
Method Details
-
runsUpperBound
protected long runsUpperBound() -
asKeyIndicesChunk
Description copied from interface:OrderedKeys
Get aLongChunk
representation of the individual keys in thisOrderedKeys
.- Specified by:
asKeyIndicesChunk
in interfaceOrderedKeys
- Returns:
- A
LongChunk
containing the keys in thisOrderedKeys
-
asKeyRangesChunk
Description copied from interface:OrderedKeys
Get aLongChunk
representation of key ranges in thisOrderedKeys
.- Specified by:
asKeyRangesChunk
in interfaceOrderedKeys
- Returns:
- A
LongChunk
containing the key ranges in thisOrderedKeys
-
lastKey
public abstract long lastKey()Description copied from interface:OrderedKeys
Get the last key in thisOrderedKeys
.- Specified by:
lastKey
in interfaceOrderedKeys
- Returns:
- The last key, or
ReadOnlyIndex.NULL_KEY
if there is none.
-
rangesCountUpperBound
public abstract long rangesCountUpperBound() -
close
public void close()Description copied from interface:OrderedKeys
Free any resources associated with this object.
Using any
OrderedKeys
methods afterclose()
is an error and may produce exceptions or undefined results.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceOrderedKeys
- Specified by:
close
in interfaceSafeCloseable
-
closeOrderedKeysAsChunkImpl
protected final void closeOrderedKeysAsChunkImpl() -
invalidateOrderedKeysAsChunkImpl
protected final void invalidateOrderedKeysAsChunkImpl()
-