Package com.illumon.iris.db.v2.sources
Interface ReverseLookupColumnSource<DATA_TYPE,EXTRA_VALUE_TYPE>
- All Superinterfaces:
ChunkSource<Attributes.Values>
,ChunkSource.WithPrev<Attributes.Values>
,ColumnSource<DATA_TYPE>
,DefaultChunkSource<Attributes.Values>
,DefaultChunkSource.WithPrev<Attributes.Values>
,ElementSource<DATA_TYPE>
,FillContextMaker
,GetContextMaker
,Releasable
,StringSetImpl.ReversibleLookup<DATA_TYPE>
,TupleExporter<DATA_TYPE>
,TupleSource<DATA_TYPE>
public interface ReverseLookupColumnSource<DATA_TYPE,EXTRA_VALUE_TYPE> extends ColumnSource<DATA_TYPE>, StringSetImpl.ReversibleLookup<DATA_TYPE>
Common interface for column sources that provide a reverse-lookup function (value to int key). Note that int keys
are used because this is intended for column sources with a small, contiguous key range starting from 0 and well
shorter than Integer.MAX_VALUE.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.illumon.iris.db.v2.sources.chunk.ChunkSource
ChunkSource.FillContext, ChunkSource.GetContext, ChunkSource.WithPrev<ATTR extends Attributes.Any>
Nested classes/interfaces inherited from interface com.illumon.iris.db.v2.sources.chunk.DefaultChunkSource
DefaultChunkSource.SupportsContiguousGet<ATTR extends Attributes.Any>, DefaultChunkSource.WithPrev<ATTR extends Attributes.Any>
-
Field Summary
Fields inherited from interface com.illumon.iris.db.v2.sources.chunk.ChunkSource
DEFAULT_FILL_INSTANCE, ZERO_LENGTH_CHUNK_SOURCE_ARRAY
Fields inherited from interface com.illumon.iris.db.v2.sources.chunk.ChunkSource.WithPrev
ZERO_LENGTH_CHUNK_SOURCE_WITH_PREV_ARRAY
Fields inherited from interface com.illumon.iris.db.v2.sources.ColumnSource
ZERO_LENGTH_COLUMN_SOURCE_ARRAY
-
Method Summary
Modifier and Type Method Description EXTRA_VALUE_TYPE
getExtra()
Get an implementation-defined "extra value" associated with this column source.ToIntFunction<DATA_TYPE>
getReverseLookup(int highestKeyNeeded)
Get a reverse-lookup function for all non-null values stored in this column source atkeys <= highestKeyNeeded
.default int
rget(int highestIndex, DATA_TYPE value)
Perform a reverse lookupMethods inherited from interface com.illumon.iris.db.v2.sources.chunk.ChunkSource
fillChunk, getChunkType
Methods inherited from interface com.illumon.iris.db.v2.sources.chunk.ChunkSource.WithPrev
fillPrevChunk
Methods inherited from interface com.illumon.iris.db.v2.sources.ColumnSource
allowsReinterpret, cast, createPreviousTuple, createTuple, createTupleFromValues, exportElement, exportElement, exportToExternalKey, getColumnSources, getComponentType, getGroupingBuilder, getGroupingProvider, getNativeType, getPrevSource, getType, hasGrouping, isImmutable, match, reinterpret, releaseCachedResources, setGroupingProvider, startTrackingPrevValues
Methods inherited from interface com.illumon.iris.db.v2.sources.chunk.DefaultChunkSource
getChunk, getChunk, getChunkByFilling, makeFillContext, makeGetContext
Methods inherited from interface com.illumon.iris.db.v2.sources.chunk.DefaultChunkSource.WithPrev
getPrevChunk, getPrevChunk, getPrevChunkByFilling
Methods inherited from interface com.illumon.iris.db.v2.sources.ElementSource
get, getBoolean, getByte, getChar, getDouble, getFloat, getInt, getLong, getPrev, getPrevBoolean, getPrevByte, getPrevChar, getPrevDouble, getPrevFloat, getPrevInt, getPrevLong, getPrevShort, getShort
Methods inherited from interface com.illumon.iris.db.v2.sources.chunk.FillContextMaker
makeFillContext
Methods inherited from interface com.illumon.iris.db.v2.sources.chunk.GetContextMaker
makeGetContext
Methods inherited from interface com.illumon.iris.db.v2.tuples.TupleExporter
exportElementReinterpreted
Methods inherited from interface com.illumon.iris.db.v2.tuples.TupleSource
createTupleFromReinterpretedValues
-
Method Details
-
getReverseLookup
Get a reverse-lookup function for all non-null values stored in this column source atkeys <= highestKeyNeeded
.- Parameters:
highestKeyNeeded
- The highest key needed in the result map- Returns:
- A reverse-lookup function that has all values defined for keys in [0, highestKeyNeeded]
-
getExtra
EXTRA_VALUE_TYPE getExtra()Get an implementation-defined "extra value" associated with this column source. -
rget
Perform a reverse lookup- Specified by:
rget
in interfaceStringSetImpl.ReversibleLookup<DATA_TYPE>
- Parameters:
highestIndex
- The highest key needed for the lookupvalue
- The value we are looking up- Returns:
- The key, between 0 and highestIndex, for the value. A value outside this range if the value has no mapping in the range.
-