public class ArrowSchema extends Object implements BaseStruct
Represents a wrapper for the following C structure:
struct ArrowSchema {
// Array type description
const char* format;
const char* name;
const char* metadata;
int64_t flags;
int64_t n_children;
struct ArrowSchema** children;
struct ArrowSchema* dictionary;
// Release callback
void (*release)(struct ArrowSchema*);
// Opaque producer-specific data
void* private_data;
};
| Modifier and Type | Class and Description |
|---|---|
static class |
ArrowSchema.Snapshot
Snapshot of the ArrowSchema raw data.
|
| Modifier and Type | Method and Description |
|---|---|
static ArrowSchema |
allocateNew(BufferAllocator allocator)
Create ArrowSchema by allocating memory.
|
void |
close()
Close to release the main buffer.
|
long |
memoryAddress()
Get memory address.
|
void |
release()
Call the release callback of an ArrowArray.
|
void |
save(ArrowSchema.Snapshot snapshot)
Write values from Snapshot to the underlying ArrowSchema memory buffer.
|
ArrowSchema.Snapshot |
snapshot()
Take a snapshot of the ArrowSchema raw values.
|
static ArrowSchema |
wrap(long memoryAddress)
Create ArrowSchema from an existing memory address.
|
public static ArrowSchema wrap(long memoryAddress)
The resulting ArrowSchema does not own the memory.
memoryAddress - Memory address to wrappublic static ArrowSchema allocateNew(BufferAllocator allocator)
The resulting ArrowSchema owns the memory.
allocator - Allocator for memory allocationspublic long memoryAddress()
BaseStructmemoryAddress in interface BaseStructpublic void release()
BaseStructThis function must not be called for child arrays.
release in interface BaseStructpublic void close()
BaseStructclose in interface AutoCloseableclose in interface BaseStructpublic ArrowSchema.Snapshot snapshot()
public void save(ArrowSchema.Snapshot snapshot)
Copyright © 2024 The Apache Software Foundation. All rights reserved.