pub trait DynVTable:
'static
+ Sealed
+ Send
+ Sync
+ Debug {
// Required methods
fn build(
&self,
id: ArrayId,
dtype: &DType,
len: usize,
metadata: &[u8],
buffers: &[BufferHandle],
children: &dyn ArrayChildren,
session: &VortexSession,
) -> VortexResult<ArrayRef>;
fn with_children(
&self,
array: &dyn Array,
children: Vec<ArrayRef>,
) -> VortexResult<ArrayRef>;
fn reduce(&self, array: &ArrayRef) -> VortexResult<Option<ArrayRef>>;
fn reduce_parent(
&self,
array: &ArrayRef,
parent: &ArrayRef,
child_idx: usize,
) -> VortexResult<Option<ArrayRef>>;
fn execute(
&self,
array: &ArrayRef,
ctx: &mut ExecutionCtx,
) -> VortexResult<ArrayRef>;
fn execute_parent(
&self,
array: &ArrayRef,
parent: &ArrayRef,
child_idx: usize,
ctx: &mut ExecutionCtx,
) -> VortexResult<Option<ArrayRef>>;
}Expand description
Dynamically typed vtable trait.
This trait is sealed, therefore users should implement the strongly typed VTable trait
instead. The ArrayVTableExt::vtable function can be used to lift the implementation into
this object-safe form.
This trait contains the implementation API for Vortex arrays, allowing us to keep the public
Array trait API to a minimum.
Required Methods§
fn build( &self, id: ArrayId, dtype: &DType, len: usize, metadata: &[u8], buffers: &[BufferHandle], children: &dyn ArrayChildren, session: &VortexSession, ) -> VortexResult<ArrayRef>
fn with_children( &self, array: &dyn Array, children: Vec<ArrayRef>, ) -> VortexResult<ArrayRef>
Sourcefn reduce(&self, array: &ArrayRef) -> VortexResult<Option<ArrayRef>>
fn reduce(&self, array: &ArrayRef) -> VortexResult<Option<ArrayRef>>
See VTable::reduce
Sourcefn reduce_parent(
&self,
array: &ArrayRef,
parent: &ArrayRef,
child_idx: usize,
) -> VortexResult<Option<ArrayRef>>
fn reduce_parent( &self, array: &ArrayRef, parent: &ArrayRef, child_idx: usize, ) -> VortexResult<Option<ArrayRef>>
Sourcefn execute(
&self,
array: &ArrayRef,
ctx: &mut ExecutionCtx,
) -> VortexResult<ArrayRef>
fn execute( &self, array: &ArrayRef, ctx: &mut ExecutionCtx, ) -> VortexResult<ArrayRef>
See VTable::execute