Class NullChunkWriter

java.lang.Object
io.deephaven.extensions.barrage.chunk.BaseChunkWriter<Chunk<Values>>
io.deephaven.extensions.barrage.chunk.NullChunkWriter
All Implemented Interfaces:
ChunkWriter<Chunk<Values>>

public class NullChunkWriter extends BaseChunkWriter<Chunk<Values>>
A ChunkWriter implementation that writes an Apache Arrow Null Column; which only writes a field node.
  • Field Details

  • Constructor Details

    • NullChunkWriter

      public NullChunkWriter()
  • Method Details

    • getInputStream

      public ChunkWriter.DrainableColumn getInputStream(@NotNull @NotNull ChunkWriter.Context chunk, @Nullable @Nullable RowSet subset, @NotNull @NotNull BarrageOptions options) throws IOException
      Description copied from interface: ChunkWriter
      Get an input stream optionally position-space filtered using the provided RowSet.
      Parameters:
      chunk - the chunk writer context holding the data to be drained to the client
      subset - if provided, is a position-space filter of source data
      options - options for writing to the stream
      Returns:
      a single-use DrainableColumn ready to be drained via grpc
      Throws:
      IOException
    • computeNullCount

      protected int computeNullCount(@NotNull @NotNull ChunkWriter.Context context, @NotNull @NotNull RowSequence subset)
      Description copied from class: BaseChunkWriter
      Compute the number of nulls in the subset.
      Specified by:
      computeNullCount in class BaseChunkWriter<Chunk<Values>>
      Parameters:
      context - the context for the chunk
      subset - the subset of rows to consider
      Returns:
      the number of nulls in the subset
    • writeValidityBufferInternal

      protected void writeValidityBufferInternal(@NotNull @NotNull ChunkWriter.Context context, @NotNull @NotNull RowSequence subset, @NotNull @NotNull BaseChunkWriter.SerContext serContext)
      Description copied from class: BaseChunkWriter
      Update the validity buffer for the subset.
      Specified by:
      writeValidityBufferInternal in class BaseChunkWriter<Chunk<Values>>
      Parameters:
      context - the context for the chunk
      subset - the subset of rows to consider
      serContext - the serialization context