importArray

fnArrayData importArray(const ArrowArray arr, DataType dtype, bool largeOffsets = true, const ArrowSchema * schema = null) @trusted

Imports an ArrowArray into a fresh sealed chunk (copy-on-import: the foreign buffers are copied, the source's release fires normally, and no foreign memory is held after the return). The ABI's offset field is honored - the imported window is [offset .. offset + length) with the validity bits re-based to slot 0. A null_count of -1 (unknown) is computed from the validity bitmap; a zero null count ignores the validity buffer (all valid, the sentinel form). The ABI carries no buffer lengths, so what is checkable is checked (buffer counts, offset and length sanity, monotonic non-negative string offsets) and the rest is the documented FFI trust boundary.

Parameters

arrthe exported array
dtypethe target dtype
largeOffsetswhether STRING offsets are int64 ("U" large_string); int32 "u" offsets widen on import

Returns

the sealed chunk.

Throws

DataFrameException on unsupported layouts or inconsistent

metadata (never a partial chunk).

fnArrayData importArray(const ArrowArray arr, const ArrowSchema * schema) @trusted

Ditto, schema-driven: the dtype and the offsets width come from the paired ArrowSchema (the ABI's intended entry).