#[repr(C)]pub struct FFI_ArrowArrayStream {
pub get_schema: Option<unsafe extern "C" fn(arg1: *mut Self, out: *mut FFI_ArrowSchema) -> c_int>,
pub get_next: Option<unsafe extern "C" fn(arg1: *mut Self, out: *mut FFI_ArrowArray) -> c_int>,
pub get_last_error: Option<unsafe extern "C" fn(arg1: *mut Self) -> *const c_char>,
pub release: Option<unsafe extern "C" fn(arg1: *mut Self)>,
pub private_data: *mut c_void,
}
Expand description
ABI-compatible struct for ArrayStream
from C Stream Interface
See https://arrow.apache.org/docs/format/CStreamInterface.html#structure-definitions
This was created by bindgen
Fields§
§get_schema: Option<unsafe extern "C" fn(arg1: *mut Self, out: *mut FFI_ArrowSchema) -> c_int>
C function to get schema from the stream
get_next: Option<unsafe extern "C" fn(arg1: *mut Self, out: *mut FFI_ArrowArray) -> c_int>
C function to get next array from the stream
get_last_error: Option<unsafe extern "C" fn(arg1: *mut Self) -> *const c_char>
C function to get the error from last operation on the stream
release: Option<unsafe extern "C" fn(arg1: *mut Self)>
C function to release the stream
private_data: *mut c_void
Private data used by the stream
Implementations§
Source§impl FFI_ArrowArrayStream
impl FFI_ArrowArrayStream
Sourcepub fn new(batch_reader: Box<dyn RecordBatchReader + Send>) -> Self
pub fn new(batch_reader: Box<dyn RecordBatchReader + Send>) -> Self
Creates a new FFI_ArrowArrayStream
.
Sourcepub unsafe fn from_raw(raw_stream: *mut FFI_ArrowArrayStream) -> Self
pub unsafe fn from_raw(raw_stream: *mut FFI_ArrowArrayStream) -> Self
Takes ownership of the pointed to FFI_ArrowArrayStream
This acts to move the data out of raw_stream
, setting the release callback to NULL
§Safety
raw_stream
must be valid for reads and writesraw_stream
must be properly alignedraw_stream
must point to a properly initialized value ofFFI_ArrowArrayStream
Sourcepub fn empty() -> Self
pub fn empty() -> Self
Creates a new empty FFI_ArrowArrayStream. Used to import from the C Stream Interface.
Trait Implementations§
Source§impl Debug for FFI_ArrowArrayStream
impl Debug for FFI_ArrowArrayStream
Source§impl Drop for FFI_ArrowArrayStream
impl Drop for FFI_ArrowArrayStream
impl Send for FFI_ArrowArrayStream
Auto Trait Implementations§
impl Freeze for FFI_ArrowArrayStream
impl RefUnwindSafe for FFI_ArrowArrayStream
impl !Sync for FFI_ArrowArrayStream
impl Unpin for FFI_ArrowArrayStream
impl UnwindSafe for FFI_ArrowArrayStream
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more