@Internal public final class ArrowUtils extends Object
Constructor and Description |
---|
ArrowUtils() |
Modifier and Type | Method and Description |
---|---|
static void |
checkArrowUsable() |
static org.apache.flink.table.runtime.arrow.ArrowUtils.CustomIterator<byte[]> |
collectAsPandasDataFrame(org.apache.flink.table.api.Table table,
int maxArrowBatchSize)
Convert Flink table to Pandas DataFrame.
|
static ArrowReader |
createArrowReader(org.apache.arrow.vector.VectorSchemaRoot root,
org.apache.flink.table.types.logical.RowType rowType)
Creates an
ArrowReader for the specified VectorSchemaRoot . |
static ArrowTableSource |
createArrowTableSource(org.apache.flink.table.types.DataType dataType,
String fileName) |
static org.apache.flink.table.data.vector.ColumnVector |
createColumnVector(org.apache.arrow.vector.ValueVector vector,
org.apache.flink.table.types.logical.LogicalType fieldType) |
static ArrowWriter<org.apache.flink.table.data.RowData> |
createRowDataArrowWriter(org.apache.arrow.vector.VectorSchemaRoot root,
org.apache.flink.table.types.logical.RowType rowType)
Creates an
ArrowWriter for the specified VectorSchemaRoot . |
static org.apache.arrow.memory.RootAllocator |
getRootAllocator() |
static byte[][] |
readArrowBatches(ReadableByteChannel channel) |
static org.apache.arrow.vector.types.pojo.Schema |
toArrowSchema(org.apache.flink.table.types.logical.RowType rowType)
Returns the Arrow schema of the specified type.
|
public static org.apache.arrow.memory.RootAllocator getRootAllocator()
public static void checkArrowUsable()
public static org.apache.arrow.vector.types.pojo.Schema toArrowSchema(org.apache.flink.table.types.logical.RowType rowType)
public static ArrowWriter<org.apache.flink.table.data.RowData> createRowDataArrowWriter(org.apache.arrow.vector.VectorSchemaRoot root, org.apache.flink.table.types.logical.RowType rowType)
ArrowWriter
for the specified VectorSchemaRoot
.public static ArrowReader createArrowReader(org.apache.arrow.vector.VectorSchemaRoot root, org.apache.flink.table.types.logical.RowType rowType)
ArrowReader
for the specified VectorSchemaRoot
.public static org.apache.flink.table.data.vector.ColumnVector createColumnVector(org.apache.arrow.vector.ValueVector vector, org.apache.flink.table.types.logical.LogicalType fieldType)
public static ArrowTableSource createArrowTableSource(org.apache.flink.table.types.DataType dataType, String fileName) throws IOException
IOException
public static byte[][] readArrowBatches(ReadableByteChannel channel) throws IOException
IOException
Copyright © 2014–2022 The Apache Software Foundation. All rights reserved.