Interface ChunkColumnSource<T>
- Type Parameters:
T
- the data type of the column source
- All Superinterfaces:
ChunkSource<Values>
,ChunkSource.WithPrev<Values>
,ColumnSource<T>
,ElementSource<T>
,FillContextMaker
,GetContextMaker
,Releasable
,TupleExporter<T>
,TupleSource<T>
- All Known Implementing Classes:
ByteChunkColumnSource
,CharChunkColumnSource
,DoubleChunkColumnSource
,FloatChunkColumnSource
,IntChunkColumnSource
,LongChunkColumnSource
,ObjectChunkColumnSource
,ShortChunkColumnSource
An immutable ColumnSource that is backed by chunks.
The owner of the column source may append chunks to with the addChunk call.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.deephaven.engine.table.ChunkSource
ChunkSource.FillContext, ChunkSource.GetContext, ChunkSource.WithPrev<ATTR extends Any>
Nested classes/interfaces inherited from interface io.deephaven.engine.table.TupleExporter
TupleExporter.ExportElementFunction<TUPLE_TYPE>
-
Field Summary
Fields inherited from interface io.deephaven.engine.table.ChunkSource
DEFAULT_FILL_INSTANCE, ZERO_LENGTH_CHUNK_SOURCE_ARRAY
Fields inherited from interface io.deephaven.engine.table.ChunkSource.WithPrev
ZERO_LENGTH_CHUNK_SOURCE_WITH_PREV_ARRAY
Fields inherited from interface io.deephaven.engine.table.ColumnSource
ZERO_LENGTH_COLUMN_SOURCE_ARRAY
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addChunk
(@NotNull WritableChunk<? extends Values> chunk) Append a chunk of data to this column source.void
clear()
Reset the column source to be ready for reuse.long
getSize()
Get the size of this column source (one more than the last valid row key).static ChunkColumnSource<?>
Create a new ChunkColumnSource for the given chunk type and data type.static ChunkColumnSource<?>
make
(ChunkType chunkType, Class<?> dataType, gnu.trove.list.array.TLongArrayList sharedOffsetForData) Create a new ChunkColumnSource for the given chunk type and data type.static ChunkColumnSource<?>
make
(ChunkType chunkType, Class<?> dataType, Class<?> componentType, gnu.trove.list.array.TLongArrayList sharedOffsetForData) Create a new ChunkColumnSource for the given chunk type and data type.static <T> ChunkColumnSource<T>
Create a new ChunkColumnSource for the given chunk type and data type.Methods inherited from interface io.deephaven.engine.table.ChunkSource
fillChunk, getChunk, getChunk
Methods inherited from interface io.deephaven.engine.table.ChunkSource.WithPrev
fillPrevChunk, getPrevChunk, getPrevChunk
Methods inherited from interface io.deephaven.engine.table.ColumnSource
allowsReinterpret, cast, cast, createPreviousTuple, createTuple, createTupleFromValues, exportAllTo, exportElement, exportElement, getChunkType, getComponentType, getPrevSource, getType, isImmutable, isStateless, match, reinterpret, releaseCachedResources, startTrackingPrevValues, tupleLength
Methods inherited from interface io.deephaven.engine.table.ElementSource
get, getBoolean, getByte, getChar, getDouble, getFloat, getInt, getLong, getPrev, getPrevBoolean, getPrevByte, getPrevChar, getPrevDouble, getPrevFloat, getPrevInt, getPrevLong, getPrevShort, getShort
Methods inherited from interface io.deephaven.engine.table.FillContextMaker
makeFillContext, makeFillContext
Methods inherited from interface io.deephaven.engine.table.GetContextMaker
makeGetContext, makeGetContext
Methods inherited from interface io.deephaven.engine.table.TupleExporter
exportAllReinterpretedTo, exportAllReinterpretedTo, exportAllTo, exportElementReinterpreted
Methods inherited from interface io.deephaven.engine.table.TupleSource
createTupleFromReinterpretedValues
-
Method Details
-
make
Create a new ChunkColumnSource for the given chunk type and data type.- Parameters:
chunkType
- the type of chunkdataType
- the datatype for the newly created column source- Returns:
- an empty ChunkColumnSource
-
make
static <T> ChunkColumnSource<T> make(ChunkType chunkType, Class<T> dataType, Class<?> componentType) Create a new ChunkColumnSource for the given chunk type and data type.- Parameters:
chunkType
- the type of chunkdataType
- the datatype for the newly created column sourcecomponentType
- the component type for the newly created column source (only applies to Objects)- Returns:
- an empty ChunkColumnSource
-
make
static ChunkColumnSource<?> make(ChunkType chunkType, Class<?> dataType, gnu.trove.list.array.TLongArrayList sharedOffsetForData) Create a new ChunkColumnSource for the given chunk type and data type.- Parameters:
chunkType
- the type of chunkdataType
- the datatype for the newly created column sourcesharedOffsetForData
- an array list representing the shared offsets for data across several ChunkColumnSources- Returns:
- an empty ChunkColumnSource
-
make
static ChunkColumnSource<?> make(ChunkType chunkType, Class<?> dataType, Class<?> componentType, gnu.trove.list.array.TLongArrayList sharedOffsetForData) Create a new ChunkColumnSource for the given chunk type and data type.- Parameters:
chunkType
- the type of chunkdataType
- the datatype for the newly created column sourcecomponentType
- the component type for the newly created column source (only applies to Objects)sharedOffsetForData
- an array list representing the shared offsets for data across several ChunkColumnSources- Returns:
- an empty ChunkColumnSource
-
addChunk
Append a chunk of data to this column source. The chunk must not be empty (i.e., the size must be greater than zero).- Parameters:
chunk
- the chunk of data to add
-
clear
void clear()Reset the column source to be ready for reuse.Clear will discard the currently held chunks. This should not be called if a table will continue to reference the column source; as it violates the immutability contract.
-
getSize
long getSize()Get the size of this column source (one more than the last valid row key).- Returns:
- the size of this column source
-