Class VarBinaryChunkWriter<T>
java.lang.Object
io.deephaven.extensions.barrage.chunk.BaseChunkWriter<ObjectChunk<T,Values>>
io.deephaven.extensions.barrage.chunk.VarBinaryChunkWriter<T>
- All Implemented Interfaces:
ChunkWriter<ObjectChunk<T,Values>>
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfacestatic classfinal classNested classes/interfaces inherited from class io.deephaven.extensions.barrage.chunk.BaseChunkWriter
BaseChunkWriter.BulkIntWriter, BaseChunkWriter.ChunkTransformer<SOURCE_CHUNK_TYPE extends Chunk<Values>>, BaseChunkWriter.ValidityBufferNested classes/interfaces inherited from interface io.deephaven.extensions.barrage.chunk.ChunkWriter
ChunkWriter.BufferListener, ChunkWriter.DrainableColumn, ChunkWriter.Factory, ChunkWriter.FieldNodeInfo, ChunkWriter.FieldNodeListener -
Field Summary
Fields inherited from class io.deephaven.extensions.barrage.chunk.BaseChunkWriter
BULK_WRITE_BUFFER_BYTES, dhNullable, elementSize, fieldNullable, PADDING_BUFFER, REMAINDER_MOD_8_MASK -
Constructor Summary
ConstructorsConstructorDescriptionVarBinaryChunkWriter(boolean fieldNullable, VarBinaryChunkWriter.Appender<T> appendItem) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcomputeValidity(ChunkWriter.Context context, @NotNull RowSequence subset, @NotNull BaseChunkWriter.ValidityBuffer validity) Report the nullness of each row of the subset, in order, tovalidity.getInputStream(ChunkWriter.Context context, @Nullable RowSet subset, @NotNull BarrageOptions options) Get an input stream optionally position-space filtered using the provided RowSet.makeContext(@NotNull ObjectChunk<T, Values> chunk, long rowOffset) Create a context for the given chunk.Methods inherited from class io.deephaven.extensions.barrage.chunk.BaseChunkWriter
getEmptyInputStream, getEmptyInputStream, getNumLongsForBitPackOfSize, getValidityMapSerializationSizeFor, isFieldNullableMethods 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.ChunkWriter
getInputStream
-
Constructor Details
-
VarBinaryChunkWriter
-
-
Method Details
-
getInputStream
public ChunkWriter.DrainableColumn getInputStream(@NotNull ChunkWriter.Context context, @Nullable @Nullable RowSet subset, @NotNull @NotNull BarrageOptions options) throws IOException Description copied from interface:ChunkWriterGet an input stream optionally position-space filtered using the provided RowSet.- Parameters:
context- the chunk writer context holding the data to be drained to the clientsubset- if provided, is a position-space filter of source dataoptions- options for writing to the stream- Returns:
- a single-use DrainableColumn ready to be drained via grpc
- Throws:
IOException
-
makeContext
public VarBinaryChunkWriter<T>.Context makeContext(@NotNull @NotNull ObjectChunk<T, Values> chunk, long rowOffset) Description copied from interface:ChunkWriterCreate a context for the given chunk.- Specified by:
makeContextin interfaceChunkWriter<T>- Overrides:
makeContextin classBaseChunkWriter<ObjectChunk<T,Values>> - Parameters:
chunk- the chunk of data to be writtenrowOffset- the offset into the logical message potentially spread over multiple chunks- Returns:
- a context for the given chunk
-
computeValidity
protected void computeValidity(@NotNull ChunkWriter.Context context, @NotNull @NotNull RowSequence subset, @NotNull @NotNull BaseChunkWriter.ValidityBuffer validity) Description copied from class:BaseChunkWriterReport the nullness of each row of the subset, in order, tovalidity.This is invoked at most once per
BaseChunkWriter.BaseChunkInputStream: the null count carried by the field node and the bytes of the validity buffer are both derived from this single traversal of the row data.- Specified by:
computeValidityin classBaseChunkWriter<ObjectChunk<T,Values>> - Parameters:
context- the context for the chunksubset- the subset of rows to considervalidity- the validity buffer to populate
-