public class ArrowArray extends Object implements BaseStruct
Represents a wrapper for the following C structure:
struct ArrowArray {
// Array data description
int64_t length;
int64_t null_count;
int64_t offset;
int64_t n_buffers;
int64_t n_children;
const void** buffers;
struct ArrowArray** children;
struct ArrowArray* dictionary;
// Release callback
void (*release)(struct ArrowArray*);
// Opaque producer-specific data
void* private_data;
};
| Modifier and Type | Class and Description |
|---|---|
static class |
ArrowArray.Snapshot
Snapshot of the ArrowArray raw data.
|
| Modifier and Type | Method and Description |
|---|---|
static ArrowArray |
allocateNew(BufferAllocator allocator)
Create ArrowArray by allocating memory.
|
void |
close()
Close to release the main buffer.
|
void |
markReleased()
Mark the array as released.
|
long |
memoryAddress()
Get memory address.
|
void |
release()
Call the release callback of an ArrowArray.
|
void |
save(ArrowArray.Snapshot snapshot)
Write values from Snapshot to the underlying ArrowArray memory buffer.
|
ArrowArray.Snapshot |
snapshot()
Take a snapshot of the ArrowArray raw values.
|
static ArrowArray |
wrap(long memoryAddress)
Create ArrowArray from an existing memory address.
|
public static ArrowArray wrap(long memoryAddress)
The resulting ArrowArray does not own the memory.
memoryAddress - Memory address to wrappublic static ArrowArray allocateNew(BufferAllocator allocator)
The resulting ArrowArray owns the memory.
allocator - Allocator for memory allocationspublic void markReleased()
public 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 ArrowArray.Snapshot snapshot()
public void save(ArrowArray.Snapshot snapshot)
Copyright © 2024 The Apache Software Foundation. All rights reserved.