Class RunEndEncodedChunkReader
java.lang.Object
io.deephaven.extensions.barrage.chunk.BaseChunkReader<WritableChunk<Values>>
io.deephaven.extensions.barrage.chunk.RunEndEncodedChunkReader
- All Implemented Interfaces:
ChunkReader<WritableChunk<Values>>
Reads an Arrow Run-End Encoded (REE) column from the wire into a flat Deephaven chunk.
The REE parent array has logical length numRows, null_count 0, and zero buffers. The reader consumes
one parent ChunkWriter.FieldNodeInfo (no parent buffers), then reads the two children:
run_ends— non-nullable Int16/Int32/Int64,numRunscumulative 1-based end indices (last == numRows)values— the encoded value type, one value per run
numRows and the same element type as the values child.-
Nested Class Summary
Nested classes/interfaces inherited from class io.deephaven.extensions.barrage.chunk.BaseChunkReader
BaseChunkReader.ChunkTransformer<READ_CHUNK_TYPE extends Chunk<Values>,DEST_CHUNK_TYPE extends WritableChunk<Values>> Nested classes/interfaces inherited from interface io.deephaven.extensions.barrage.chunk.ChunkReader
ChunkReader.Factory -
Field Summary
Fields inherited from class io.deephaven.extensions.barrage.chunk.BaseChunkReader
BULK_READ_BUFFER_BYTES -
Constructor Summary
ConstructorsConstructorDescriptionRunEndEncodedChunkReader(@NotNull ChunkReader<? extends WritableChunk<Values>> runEndsReader, @NotNull ChunkReader<? extends WritableChunk<Values>> valuesReader, @NotNull ChunkType valuesChunkType) -
Method Summary
Modifier and TypeMethodDescriptionreadChunk(@NotNull Iterator<ChunkWriter.FieldNodeInfo> fieldNodeIter, PrimitiveIterator.OfLong bufferInfoIter, @NotNull DataInput is, @Nullable WritableChunk<Values> outChunk, int outOffset, int totalRows) Reads the given DataInput to extract the next Arrow buffer as a Deephaven Chunk.Methods inherited from class io.deephaven.extensions.barrage.chunk.BaseChunkReader
castOrCreateChunk, getChunkTypeFor, readValidityBufferMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.deephaven.extensions.barrage.chunk.ChunkReader
readChunk
-
Constructor Details
-
RunEndEncodedChunkReader
public RunEndEncodedChunkReader(@NotNull @NotNull ChunkReader<? extends WritableChunk<Values>> runEndsReader, @NotNull @NotNull ChunkReader<? extends WritableChunk<Values>> valuesReader, @NotNull @NotNull ChunkType valuesChunkType)
-
-
Method Details
-
readChunk
public WritableChunk<Values> readChunk(@NotNull @NotNull Iterator<ChunkWriter.FieldNodeInfo> fieldNodeIter, @NotNull PrimitiveIterator.OfLong bufferInfoIter, @NotNull @NotNull DataInput is, @Nullable @Nullable WritableChunk<Values> outChunk, int outOffset, int totalRows) throws IOException Description copied from interface:ChunkReaderReads the given DataInput to extract the next Arrow buffer as a Deephaven Chunk.- Parameters:
fieldNodeIter- iterator to read fields from the streambufferInfoIter- iterator to read buffers from the streamis- input stream containing buffers to be readoutChunk- chunk to write tooutOffset- offset within the outChunk to begin writingtotalRows- total rows to write to the outChunk- Returns:
- a Chunk containing the data from the stream
- Throws:
IOException- if an error occurred while reading the stream
-