Class SortedRangesPacked<ArrayType>
java.lang.Object
com.illumon.iris.db.v2.utils.RefCountedCow<SortedRanges>
com.illumon.iris.db.v2.utils.sortedranges.SortedRanges
com.illumon.iris.db.v2.utils.sortedranges.SortedRangesTyped<ArrayType>
com.illumon.iris.db.v2.utils.sortedranges.SortedRangesPacked<ArrayType>
- All Implemented Interfaces:
TreeIndexImpl
- Direct Known Subclasses:
SortedRangesInt
,SortedRangesShort
-
Nested Class Summary
Nested classes/interfaces inherited from class com.illumon.iris.db.v2.utils.sortedranges.SortedRanges
SortedRanges.RangeIterator
Nested classes/interfaces inherited from interface com.illumon.iris.db.v2.utils.TreeIndexImpl
TreeIndexImpl.RandomBuilder, TreeIndexImpl.SequentialBuilder
-
Field Summary
FieldsFields inherited from class com.illumon.iris.db.v2.utils.sortedranges.SortedRangesTyped
data
Fields inherited from class com.illumon.iris.db.v2.utils.sortedranges.SortedRanges
cardinality, count, DEBUG, ELEMENTS_PER_BLOCK_DENSE_THRESHOLD, INITIAL_SIZE, INT_DENSE_MAX_CAPACITY, INT_EXTENT, INT_SPARSE_MAX_CAPACITY, LONG_DENSE_MAX_CAPACITY, LONG_EXTENT, LONG_SPARSE_MAX_CAPACITY, MAX_CAPACITY, POOL_ARRAYS, SHORT_EXTENT, SHORT_MAX_CAPACITY, USE_RANGES_ARRAY
Fields inherited from interface com.illumon.iris.db.v2.utils.TreeIndexImpl
EMPTY
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
SortedRangesPacked
(int initialCapacity, long offset) protected
SortedRangesPacked
(ArrayType data, long offset) protected
SortedRangesPacked
(ArrayType data, long offset, int count, long cardinality) -
Method Summary
Modifier and TypeMethodDescriptionfinal SortedRanges
addInternal
(long v, boolean writeCheck) final SortedRanges
addRangeInternal
(long start, long end, boolean writeCheck) final SortedRanges
appendInternal
(long v, boolean writeCheck) final SortedRanges
appendRangeInternal
(long start, long end, boolean writeCheck) applyShift
(long shiftOffset) applyShiftOnNew
(long shiftOffset) boolean
fits
(long value) boolean
fits
(long start, long end) boolean
fitsForAppend
(long end) protected abstract SortedRanges
makeMyType
(ArrayType data, long offset, int count, long cardinality) protected abstract long
protected final long
offset()
void
protected final long
pack
(long unpackedValue) protected abstract void
rebaseAndShift
(ArrayType dataOut, long newOffset, long shiftOffset, SortedRangesTyped<ArrayType> sar, long first) final SortedRanges
removeInternal
(long v) final SortedRanges
removeRangeInternal
(long start, long end) protected final long
unpack
(long packedValue) Methods inherited from class com.illumon.iris.db.v2.utils.sortedranges.SortedRangesTyped
capacityForLastIndex, checkSizeAndMoveData, copyData, copyData, copyData, copyDataForMoveToNew, copyTo, ensureCanAppend, freeArray, makeArray, makeMyTypeAndOffset, moveData, tryCompactUnsafe, tryMakePackedType
Methods inherited from class com.illumon.iris.db.v2.utils.sortedranges.SortedRanges
absPackedGet, absUnpackedGet, add, addPacked, addPackedWithStart, addRange, addRangePacked, addRangePackedWithStart, addRangeUnsafe, addUnsafe, append, appendPacked, appendRange, appendRangePacked, appendRangeUnpacked, appendRangeUnsafe, appendUnsafe, arraySizeRoundingInt, arraySizeRoundingShort, bytesAllocated, bytesUsed, clear, close, close2, contains, containsRange, count, dataLength, dataToDebugString, deepCopy, find, first, forEachLong, forEachLongRange, get, getAverageRunLengthEstimate, getCardinality, getIterator, getKeysForPositions, getOrderedKeysByKeyRange, getOrderedKeysByPosition, getOrderedKeysByPositionWithStart, getOrderedKeysIterator, getRangeIterator, getReverseIterator, getSearchIterator, growOnNew, hasMoreThanOneRange, insertImpl, insertImpl, intArrayCapacityForLastIndex, intersectOnNew, intersectOnNewImpl, invertOnNew, invertRangeOnNew, isDense, isDenseInt, isDenseLong, isDenseLongSample, isDenseShort, isEmpty, isIntAllocationSize, isLongAllocationSize, isShortAllocationSize, isSparse, ixAppendRange, ixCardinality, ixCompact, ixContainsRange, ixCowRef, ixFind, ixFirstKey, ixForEachLong, ixForEachLongRange, ixGet, ixGetAverageRunLengthEstimate, ixGetKeysForPositions, ixGetOrderedKeysByKeyRange, ixGetOrderedKeysByPosition, ixGetOrderedKeysIterator, ixInsert, ixInsert, ixInsertRange, ixInsertSecondHalf, ixInsertWithShift, ixIntersectOnNew, ixInvertOnNew, ixIsEmpty, ixIterator, ixLastKey, ixMinusOnNew, ixOverlaps, ixOverlapsRange, ixRangeIterator, ixRangesCountUpperBound, ixRefCount, ixRelease, ixRemove, ixRemove, ixRemoveRange, ixRemoveSecondHalf, ixRetain, ixRetainRange, ixReverseIterator, ixSearchIterator, ixShiftInPlace, ixShiftOnNew, ixSubindexByKeyOnNew, ixSubindexByPosOnNew, ixSubsetOf, ixToRspOnNew, ixUnionOnNew, ixUpdate, ixValidate, last, longArrayCapacityForLastIndex, makeEmpty, makeForKnownRange, makeSingleElement, makeSingleRange, mergeAppend, overlaps, overlapsRange, packedGet, packedSet, packedValuesPerCacheLine, remove, remove, removePacked, removeRange, removeRangePacked, removeRangePackedWithStart, retainRange, self, shortArrayCapacityForLastIndex, subRangesByKey, subRangesByPos, subsetOf, toDebugString, toRsp, toString, tryCompact, tryMakeForKnownRangeFinalCapacityLowerBound, tryMakeForKnownRangeKnownCount, tryMakeForKnownRangeUnknownMaxCapacity, tryPack, tryPackFor, tryPackWithNewLast, unionOnNew, unionOnNewLegacy, unpackedGet, unpackedSet, validate, validate, validate
Methods inherited from class com.illumon.iris.db.v2.utils.RefCountedCow
acquire, canWrite, cowRef, getWriteRef, notifyAfterRelease, notifyBeforeAcquire, refCount, release
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.illumon.iris.db.v2.utils.TreeIndexImpl
ixInsert, ixRemove, ixValidate
-
Field Details
-
offset
protected long offset
-
-
Constructor Details
-
SortedRangesPacked
protected SortedRangesPacked(int initialCapacity, long offset) -
SortedRangesPacked
-
SortedRangesPacked
-
-
Method Details
-
maxValueForType
protected abstract long maxValueForType() -
fits
public boolean fits(long value) - Specified by:
fits
in classSortedRanges
-
fits
public boolean fits(long start, long end) - Specified by:
fits
in classSortedRanges
-
fitsForAppend
public boolean fitsForAppend(long end) - Specified by:
fitsForAppend
in classSortedRanges
-
pack
protected final long pack(long unpackedValue) - Specified by:
pack
in classSortedRanges
-
unpack
protected final long unpack(long packedValue) - Specified by:
unpack
in classSortedRanges
-
makeMyType
protected abstract SortedRanges makeMyType(ArrayType data, long offset, int count, long cardinality) -
offset
protected final long offset() -
addInternal
- Specified by:
addInternal
in classSortedRanges
-
addRangeInternal
- Specified by:
addRangeInternal
in classSortedRanges
-
appendInternal
- Specified by:
appendInternal
in classSortedRanges
-
appendRangeInternal
- Specified by:
appendRangeInternal
in classSortedRanges
-
removeInternal
- Specified by:
removeInternal
in classSortedRanges
-
removeRangeInternal
- Specified by:
removeRangeInternal
in classSortedRanges
-
rebaseAndShift
protected abstract void rebaseAndShift(ArrayType dataOut, long newOffset, long shiftOffset, SortedRangesTyped<ArrayType> sar, long first) -
applyShift
- Specified by:
applyShift
in classSortedRanges
-
applyShiftOnNew
- Specified by:
applyShiftOnNew
in classSortedRanges
-
offsetToDebugString
- Overrides:
offsetToDebugString
in classSortedRanges
-