Class RecordBatch

java.lang.Object
com.google.flatbuffers.Table
org.apache.arrow.flatbuf.RecordBatch

public final class RecordBatch extends com.google.flatbuffers.Table
A data header describing the shared memory layout of a "record" or "row" batch. Some systems call this a "row batch" internally and others a "record batch".
  • Constructor Details

    • RecordBatch

      public RecordBatch()
  • Method Details

    • ValidateVersion

      public static void ValidateVersion()
    • getRootAsRecordBatch

      public static RecordBatch getRootAsRecordBatch(ByteBuffer _bb)
    • getRootAsRecordBatch

      public static RecordBatch getRootAsRecordBatch(ByteBuffer _bb, RecordBatch obj)
    • __init

      public void __init(int _i, ByteBuffer _bb)
    • __assign

      public RecordBatch __assign(int _i, ByteBuffer _bb)
    • length

      public long length()
      number of records / rows. The arrays in the batch should all have this length
    • nodes

      public FieldNode nodes(int j)
      Nodes correspond to the pre-ordered flattened logical schema
    • nodes

      public FieldNode nodes(FieldNode obj, int j)
    • nodesLength

      public int nodesLength()
    • nodesVector

      public FieldNode.Vector nodesVector()
    • nodesVector

      public FieldNode.Vector nodesVector(FieldNode.Vector obj)
    • buffers

      public Buffer buffers(int j)
      Buffers correspond to the pre-ordered flattened buffer tree The number of buffers appended to this list depends on the schema. For example, most primitive arrays will have 2 buffers, 1 for the validity bitmap and 1 for the values. For struct arrays, there will only be a single buffer for the validity (nulls) bitmap
    • buffers

      public Buffer buffers(Buffer obj, int j)
    • buffersLength

      public int buffersLength()
    • buffersVector

      public Buffer.Vector buffersVector()
    • buffersVector

      public Buffer.Vector buffersVector(Buffer.Vector obj)
    • compression

      public BodyCompression compression()
      Optional compression of the message body
    • compression

      public BodyCompression compression(BodyCompression obj)
    • variadicBufferCounts

      public long variadicBufferCounts(int j)
      Some types such as Utf8View are represented using a variable number of buffers. For each such Field in the pre-ordered flattened logical schema, there will be an entry in variadicBufferCounts to indicate the number of number of variadic buffers which belong to that Field in the current RecordBatch. For example, the schema col1: Struct<alpha: Int32, beta: BinaryView, gamma: Float64> col2: Utf8View contains two Fields with variadic buffers so variadicBufferCounts will have two entries, the first counting the variadic buffers of `col1.beta` and the second counting `col2`'s. This field may be omitted if and only if the schema contains no Fields with a variable number of buffers, such as BinaryView and Utf8View.
    • variadicBufferCountsLength

      public int variadicBufferCountsLength()
    • variadicBufferCountsVector

      public com.google.flatbuffers.LongVector variadicBufferCountsVector()
    • variadicBufferCountsVector

      public com.google.flatbuffers.LongVector variadicBufferCountsVector(com.google.flatbuffers.LongVector obj)
    • variadicBufferCountsAsByteBuffer

      public ByteBuffer variadicBufferCountsAsByteBuffer()
    • variadicBufferCountsInByteBuffer

      public ByteBuffer variadicBufferCountsInByteBuffer(ByteBuffer _bb)
    • createRecordBatch

      public static int createRecordBatch(com.google.flatbuffers.FlatBufferBuilder builder, long length, int nodesOffset, int buffersOffset, int compressionOffset, int variadicBufferCountsOffset)
    • startRecordBatch

      public static void startRecordBatch(com.google.flatbuffers.FlatBufferBuilder builder)
    • addLength

      public static void addLength(com.google.flatbuffers.FlatBufferBuilder builder, long length)
    • addNodes

      public static void addNodes(com.google.flatbuffers.FlatBufferBuilder builder, int nodesOffset)
    • startNodesVector

      public static void startNodesVector(com.google.flatbuffers.FlatBufferBuilder builder, int numElems)
    • addBuffers

      public static void addBuffers(com.google.flatbuffers.FlatBufferBuilder builder, int buffersOffset)
    • startBuffersVector

      public static void startBuffersVector(com.google.flatbuffers.FlatBufferBuilder builder, int numElems)
    • addCompression

      public static void addCompression(com.google.flatbuffers.FlatBufferBuilder builder, int compressionOffset)
    • addVariadicBufferCounts

      public static void addVariadicBufferCounts(com.google.flatbuffers.FlatBufferBuilder builder, int variadicBufferCountsOffset)
    • createVariadicBufferCountsVector

      public static int createVariadicBufferCountsVector(com.google.flatbuffers.FlatBufferBuilder builder, long[] data)
    • startVariadicBufferCountsVector

      public static void startVariadicBufferCountsVector(com.google.flatbuffers.FlatBufferBuilder builder, int numElems)
    • endRecordBatch

      public static int endRecordBatch(com.google.flatbuffers.FlatBufferBuilder builder)