Class StructVectorLoader

java.lang.Object
org.apache.arrow.c.StructVectorLoader

public class StructVectorLoader extends Object
Loads buffers into StructVector.
  • Constructor Details

    • StructVectorLoader

      public StructVectorLoader(Schema schema)
      Construct with a schema.

      The schema referred to here can be obtained from the struct vector. The schema here should be the children of a struct vector, not a schema containing the struct field itself. For example: Schema schema = new Schema(structVector.getField().getChildren());

      Parameters:
      schema - buffers are added based on schema.
    • StructVectorLoader

      public StructVectorLoader(Schema schema, CompressionCodec.Factory factory)
      Construct with a schema and a compression codec factory.
      Parameters:
      schema - buffers are added based on schema.
      factory - the factory to create codec.
  • Method Details

    • load

      public StructVector load(BufferAllocator allocator, ArrowRecordBatch recordBatch)
      Loads the record batch into the struct vector.

      This will not close the record batch.

      Parameters:
      recordBatch - the batch to load