Class LongShortColumnTupleSource
- All Implemented Interfaces:
ChunkSource<Attributes.Values>
,ChunkSource.WithPrev<Attributes.Values>
,DefaultChunkSource<Attributes.Values>
,DefaultChunkSource.WithPrev<Attributes.Values>
,FillContextMaker
,GetContextMaker
,TupleExporter<LongShortTuple>
,TupleSource<LongShortTuple>
TupleSource
that produces key column values from ColumnSource
types Long and Short.
Generated by TupleSourceCodeGenerator
.
-
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
FieldsModifier and TypeFieldDescriptionstatic final TwoColumnTupleSourceFactory<LongShortTuple,
Long, Short> TwoColumnTupleSourceFactory
instance to create instances ofLongShortColumnTupleSource
.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
-
Constructor Summary
ConstructorsConstructorDescriptionLongShortColumnTupleSource
(ColumnSource<Long> columnSource1, ColumnSource<Short> columnSource2) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
convertChunks
(WritableChunk<? super Attributes.Values> destination, int chunkSize, Chunk<Attributes.Values>[] chunks) final LongShortTuple
createPreviousTuple
(long indexKey) Create a tuple for previous key column values at the supplied index key.final LongShortTuple
createTuple
(long indexKey) Create a tuple for key column values at the supplied index key.final LongShortTuple
createTupleFromReinterpretedValues
(Object... values) Create a tuple for the supplied reinterpreted values (e.g., those that come from the getColumnSources after a reinterpretation byTupleSourceFactory
).final LongShortTuple
createTupleFromValues
(Object... values) Create a tuple for the supplied (boxed) values.final Object
exportElement
(LongShortTuple tuple, int elementIndex) Export a single element from the tuple, identified by its element index, to an Objectfinal <ELEMENT_TYPE>
voidexportElement
(LongShortTuple tuple, int elementIndex, WritableSource<ELEMENT_TYPE> writableSource, long destinationIndexKey) Export a single element from the tuple, identified by its element index, to the destination index key of the supplied writable source.final Object
exportElementReinterpreted
(LongShortTuple tuple, int elementIndex) Export a single element from the tuple, identified by its element index, to an Object.final Object
Export this tuple's element list as a key suitable for theTableMap
s resulting fromTable.byExternal(boolean, java.lang.String...)
.Methods inherited from class com.illumon.iris.db.v2.tuples.AbstractTupleSource
fillChunk, fillPrevChunk, getColumnSources, makeFillContext
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.sources.chunk.ChunkSource
getChunkType
Methods inherited from interface com.illumon.iris.db.v2.sources.chunk.DefaultChunkSource
getChunk, getChunk, getChunkByFilling, makeGetContext
Methods inherited from interface com.illumon.iris.db.v2.sources.chunk.DefaultChunkSource.WithPrev
getPrevChunk, getPrevChunk, getPrevChunkByFilling, getPrevSource
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
-
Field Details
-
FACTORY
TwoColumnTupleSourceFactory
instance to create instances ofLongShortColumnTupleSource
.
-
-
Constructor Details
-
LongShortColumnTupleSource
public LongShortColumnTupleSource(@NotNull ColumnSource<Long> columnSource1, @NotNull ColumnSource<Short> columnSource2)
-
-
Method Details
-
createTuple
Description copied from interface:TupleSource
Create a tuple for key column values at the supplied index key.- Parameters:
indexKey
- The index key- Returns:
- The resulting tuple
-
createPreviousTuple
Description copied from interface:TupleSource
Create a tuple for previous key column values at the supplied index key.- Parameters:
indexKey
- The index key- Returns:
- The resulting tuple
-
createTupleFromValues
Description copied from interface:TupleSource
Create a tuple for the supplied (boxed) values.- Parameters:
values
- The values- Returns:
- The resulting tuple
-
createTupleFromReinterpretedValues
Description copied from interface:TupleSource
Create a tuple for the supplied reinterpreted values (e.g., those that come from the getColumnSources after a reinterpretation byTupleSourceFactory
).- Parameters:
values
- The values- Returns:
- The resulting tuple
-
exportElement
public final <ELEMENT_TYPE> void exportElement(@NotNull LongShortTuple tuple, int elementIndex, @NotNull WritableSource<ELEMENT_TYPE> writableSource, long destinationIndexKey) Description copied from interface:TupleExporter
Export a single element from the tuple, identified by its element index, to the destination index key of the supplied writable source.For the empty tuple, this is unsupported.
For singles, this will copy the sole element, possibly in boxed form.
For doubles and longer, this will copy the specified element without any unnecessary boxing.
- Type Parameters:
ELEMENT_TYPE
- the type of the element to be exported- Parameters:
tuple
- The tuple to export an element fromelementIndex
- The element index to exportwritableSource
- The destinationdestinationIndexKey
- The destination index key
-
exportToExternalKey
Description copied from interface:TupleExporter
Export this tuple's element list as a key suitable for the
TableMap
s resulting fromTable.byExternal(boolean, java.lang.String...)
.For the empty tuple this is a unsupported.
For singles, this is the (boxed) sole element itself.
For doubles and longer, this is a newly-allocated "
SmartKey
".- Parameters:
tuple
- The tuple to export all elements from- Returns:
- The new smart key
-
exportElement
Description copied from interface:TupleExporter
Export a single element from the tuple, identified by its element index, to an ObjectFor the empty tuple, this is unsupported.
For singles, this will copy the sole element, possibly in boxed form.
For doubles and longer, this will copy the specified element without any unnecessary boxing.
- Parameters:
tuple
- The tuple to export an element fromelementIndex
- The element index to export- Returns:
- a single value from the tuple
-
exportElementReinterpreted
Description copied from interface:TupleExporter
Export a single element from the tuple, identified by its element index, to an Object. If the tuple has been internally reinterpreted, return the reinterpreted value.For the empty tuple, this is unsupported.
For singles, this will copy the sole element, possibly in boxed form.
For doubles and longer, this will copy the specified element without any unnecessary boxing.
- Parameters:
tuple
- The tuple to export an element fromelementIndex
- The element index to export- Returns:
- a single value from the tuple, possibly as a primitive
-
getNativeType
-
convertChunks
protected void convertChunks(@NotNull WritableChunk<? super Attributes.Values> destination, int chunkSize, Chunk<Attributes.Values>[] chunks) - Specified by:
convertChunks
in classAbstractTupleSource<LongShortTuple>
-