Class SingleRange
java.lang.Object
com.illumon.iris.db.v2.utils.singlerange.SingleRange
- All Implemented Interfaces:
TreeIndexImpl
- Direct Known Subclasses:
IntStartIntDeltaSingleRange
,IntStartLongDeltaSingleRange
,LongStartIntDeltaSingleRange
,LongStartLongEndSingleRange
,ShortStartShortDeltaSingleRange
,SingleIntSingleRange
,SingleLongSingleRange
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.illumon.iris.db.v2.utils.TreeIndexImpl
TreeIndexImpl.RandomBuilder, TreeIndexImpl.SequentialBuilder
-
Field Summary
Fields inherited from interface com.illumon.iris.db.v2.utils.TreeIndexImpl
EMPTY
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract SingleRange
copy()
abstract long
final TreeIndexImpl
ixAppendRange
(long startKey, long endKey) final long
final SingleRange
final boolean
ixContainsRange
(long start, long end) final SingleRange
ixCowRef()
final long
ixFind
(long key) final long
final boolean
final boolean
final long
ixGet
(long pos) final long
final void
ixGetKeysForPositions
(PrimitiveIterator.OfLong inputPositions, LongConsumer outputKeys) final OrderedKeys
ixGetOrderedKeysByKeyRange
(long startKeyInclusive, long endKeyInclusive) final OrderedKeys
ixGetOrderedKeysByPosition
(long startPositionInclusive, long length) final OrderedKeys.Iterator
final TreeIndexImpl
ixInsert
(long key) final TreeIndexImpl
ixInsert
(TreeIndexImpl added) final TreeIndexImpl
ixInsertRange
(long startKey, long endKey) final TreeIndexImpl
ixInsertSecondHalf
(LongChunk<Attributes.OrderedKeyIndices> keys, int offset, int length) final TreeIndexImpl
ixInsertWithShift
(long shiftAmount, TreeIndexImpl other) final TreeIndexImpl
ixIntersectOnNew
(TreeIndexImpl intersected) final TreeIndexImpl
ixInvertOnNew
(TreeIndexImpl keys, long maximumPosition) Invert the given index.final boolean
final long
final TreeIndexImpl
final boolean
ixOverlaps
(TreeIndexImpl impl) final boolean
ixOverlapsRange
(long start, long end) final long
final int
final void
final TreeIndexImpl
ixRemove
(long key) final TreeIndexImpl
ixRemove
(TreeIndexImpl removed) final TreeIndexImpl
ixRemoveRange
(long startKey, long endKey) final TreeIndexImpl
ixRemoveSecondHalf
(LongChunk<Attributes.OrderedKeyIndices> keys, int offset, int length) final TreeIndexImpl
ixRetain
(TreeIndexImpl other) final TreeIndexImpl
ixRetainRange
(long start, long end) final TreeIndexImpl
ixShiftInPlace
(long shiftAmount) final TreeIndexImpl
ixShiftOnNew
(long shiftAmount) final TreeIndexImpl
ixSubindexByKeyOnNew
(long startKey, long endKey) final TreeIndexImpl
ixSubindexByPosOnNew
(long startPos, long endPosExclusive) final boolean
ixSubsetOf
(TreeIndexImpl impl) final RspBitmap
final TreeIndexImpl
final TreeIndexImpl
ixUpdate
(TreeIndexImpl added, TreeIndexImpl removed) final void
ixValidate
(String failMsg) protected static int
lowBitsAsUnsignedInt
(long v) protected static short
lowBitsAsUnsignedShort
(long v) static SingleRange
make
(long start, long end) protected static long
protected static long
abstract long
rangeEnd()
abstract long
final RspBitmap
toRsp()
final SortedRanges
protected static long
unsignedIntToLong
(int unsignedInt) protected static long
unsignedShortToLong
(short unsignedShort) 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.TreeIndexImpl
ixInsert, ixRemove, ixValidate
-
Constructor Details
-
SingleRange
public SingleRange()
-
-
Method Details
-
rangeStart
public abstract long rangeStart() -
rangeEnd
public abstract long rangeEnd() -
getCardinality
public abstract long getCardinality() -
copy
-
unsignedIntToLong
protected static long unsignedIntToLong(int unsignedInt) -
maxUnsignedInt
protected static long maxUnsignedInt() -
lowBitsAsUnsignedInt
protected static int lowBitsAsUnsignedInt(long v) -
maxUnsignedShort
protected static long maxUnsignedShort() -
unsignedShortToLong
protected static long unsignedShortToLong(short unsignedShort) -
lowBitsAsUnsignedShort
protected static short lowBitsAsUnsignedShort(long v) -
make
-
ixLastKey
public final long ixLastKey()- Specified by:
ixLastKey
in interfaceTreeIndexImpl
-
ixFirstKey
public final long ixFirstKey()- Specified by:
ixFirstKey
in interfaceTreeIndexImpl
-
ixCardinality
public final long ixCardinality()- Specified by:
ixCardinality
in interfaceTreeIndexImpl
-
ixForEachLong
- Specified by:
ixForEachLong
in interfaceTreeIndexImpl
-
ixForEachLongRange
- Specified by:
ixForEachLongRange
in interfaceTreeIndexImpl
-
ixCowRef
- Specified by:
ixCowRef
in interfaceTreeIndexImpl
-
ixRelease
public final void ixRelease()- Specified by:
ixRelease
in interfaceTreeIndexImpl
-
ixRefCount
public final int ixRefCount()- Specified by:
ixRefCount
in interfaceTreeIndexImpl
-
ixInsert
- Specified by:
ixInsert
in interfaceTreeIndexImpl
-
ixInsertRange
- Specified by:
ixInsertRange
in interfaceTreeIndexImpl
-
ixInsertSecondHalf
public final TreeIndexImpl ixInsertSecondHalf(LongChunk<Attributes.OrderedKeyIndices> keys, int offset, int length) - Specified by:
ixInsertSecondHalf
in interfaceTreeIndexImpl
-
ixRemoveSecondHalf
public final TreeIndexImpl ixRemoveSecondHalf(LongChunk<Attributes.OrderedKeyIndices> keys, int offset, int length) - Specified by:
ixRemoveSecondHalf
in interfaceTreeIndexImpl
-
ixAppendRange
- Specified by:
ixAppendRange
in interfaceTreeIndexImpl
-
ixRemove
- Specified by:
ixRemove
in interfaceTreeIndexImpl
-
ixSubindexByPosOnNew
- Specified by:
ixSubindexByPosOnNew
in interfaceTreeIndexImpl
-
ixSubindexByKeyOnNew
- Specified by:
ixSubindexByKeyOnNew
in interfaceTreeIndexImpl
-
ixGet
public final long ixGet(long pos) - Specified by:
ixGet
in interfaceTreeIndexImpl
-
ixGetKeysForPositions
public final void ixGetKeysForPositions(PrimitiveIterator.OfLong inputPositions, LongConsumer outputKeys) - Specified by:
ixGetKeysForPositions
in interfaceTreeIndexImpl
-
ixFind
public final long ixFind(long key) - Specified by:
ixFind
in interfaceTreeIndexImpl
-
ixIterator
- Specified by:
ixIterator
in interfaceTreeIndexImpl
-
ixSearchIterator
- Specified by:
ixSearchIterator
in interfaceTreeIndexImpl
-
ixReverseIterator
- Specified by:
ixReverseIterator
in interfaceTreeIndexImpl
-
ixRangeIterator
- Specified by:
ixRangeIterator
in interfaceTreeIndexImpl
-
ixIsEmpty
public final boolean ixIsEmpty()- Specified by:
ixIsEmpty
in interfaceTreeIndexImpl
-
ixUpdate
- Specified by:
ixUpdate
in interfaceTreeIndexImpl
-
ixRemove
- Specified by:
ixRemove
in interfaceTreeIndexImpl
-
ixRemoveRange
- Specified by:
ixRemoveRange
in interfaceTreeIndexImpl
-
ixRetain
- Specified by:
ixRetain
in interfaceTreeIndexImpl
-
ixRetainRange
- Specified by:
ixRetainRange
in interfaceTreeIndexImpl
-
ixIntersectOnNew
- Specified by:
ixIntersectOnNew
in interfaceTreeIndexImpl
-
ixContainsRange
public final boolean ixContainsRange(long start, long end) - Specified by:
ixContainsRange
in interfaceTreeIndexImpl
-
ixOverlaps
- Specified by:
ixOverlaps
in interfaceTreeIndexImpl
-
ixOverlapsRange
public final boolean ixOverlapsRange(long start, long end) - Specified by:
ixOverlapsRange
in interfaceTreeIndexImpl
-
ixSubsetOf
- Specified by:
ixSubsetOf
in interfaceTreeIndexImpl
-
ixMinusOnNew
- Specified by:
ixMinusOnNew
in interfaceTreeIndexImpl
-
ixUnionOnNew
- Specified by:
ixUnionOnNew
in interfaceTreeIndexImpl
-
ixShiftOnNew
- Specified by:
ixShiftOnNew
in interfaceTreeIndexImpl
-
ixShiftInPlace
- Specified by:
ixShiftInPlace
in interfaceTreeIndexImpl
-
ixInsert
- Specified by:
ixInsert
in interfaceTreeIndexImpl
-
ixInsertWithShift
- Specified by:
ixInsertWithShift
in interfaceTreeIndexImpl
-
ixGetOrderedKeysByPosition
- Specified by:
ixGetOrderedKeysByPosition
in interfaceTreeIndexImpl
-
ixGetOrderedKeysByKeyRange
- Specified by:
ixGetOrderedKeysByKeyRange
in interfaceTreeIndexImpl
-
ixGetOrderedKeysIterator
- Specified by:
ixGetOrderedKeysIterator
in interfaceTreeIndexImpl
-
ixRangesCountUpperBound
public final long ixRangesCountUpperBound()- Specified by:
ixRangesCountUpperBound
in interfaceTreeIndexImpl
-
ixGetAverageRunLengthEstimate
public final long ixGetAverageRunLengthEstimate()- Specified by:
ixGetAverageRunLengthEstimate
in interfaceTreeIndexImpl
-
ixInvertOnNew
Description copied from interface:TreeIndexImpl
Invert the given index.- Specified by:
ixInvertOnNew
in interfaceTreeIndexImpl
- Parameters:
keys
- Index of keys to invertmaximumPosition
- the largest position to add to indexBuilder, inclusive- Returns:
- the inverse of index
-
toRsp
-
toSortedRanges
-
ixToRspOnNew
- Specified by:
ixToRspOnNew
in interfaceTreeIndexImpl
-
ixCompact
- Specified by:
ixCompact
in interfaceTreeIndexImpl
-
ixValidate
- Specified by:
ixValidate
in interfaceTreeIndexImpl
-