ArrowColumnBuilder#

public final class ArrowColumnBuilder implements AutoCloseable#

Column builder from Arrow data.

This builder takes in byte buffers referencing Arrow data and allows efficient building of CUDF ColumnVectors from that Arrow data. The caller can add multiple batches where each batch corresponds to Arrow data and those batches get concatenated together after being converted to CUDF ColumnVectors. This currently only supports primitive types and Strings, Decimals and nested types such as list and struct are not supported.

Constructor Summary

Method Summary

addBatch(long rows, long nullCount, ByteBuffer data, ByteBuffer validity, ByteBuffer offsets)

Add an Arrow buffer.

buildAndPutOnDevice()

Create the immutable ColumnVector, copied to the device based on the Arrow data.

close()

toString()

Constructors

public ArrowColumnBuilder(HostColumnVector.DataType type)#

Methods

public void addBatch(
long rows,
long nullCount,
ByteBuffer data,
ByteBuffer validity,
ByteBuffer offsets
)#

Add an Arrow buffer.

This API allows you to add multiple if you want them combined into a single ColumnVector. Note, this takes all data, validity, and offsets buffers, but they may not all be needed based on the data type. The buffer should be null if its not used for that type. This API only supports primitive types and Strings, Decimals and nested types such as list and struct are not supported.

Parameters:
  • rows – - number of rows in this Arrow buffer

  • nullCount – - number of null values in this Arrow buffer

  • data – - ByteBuffer of the Arrow data buffer

  • validity – - ByteBuffer of the Arrow validity buffer

  • offsets – - ByteBuffer of the Arrow offsets buffer

public final ColumnVector buildAndPutOnDevice()#

Create the immutable ColumnVector, copied to the device based on the Arrow data.

Returns:

- new ColumnVector

public void close()#
public String toString()#