pub trait EncodingVTable:
'static
+ Sync
+ Send
+ ComputeVTable {
// Required method
fn id(&self) -> EncodingId;
// Provided methods
fn decode(
&self,
parts: &ArrayParts,
ctx: &ArrayContext,
_dtype: DType,
_len: usize,
) -> VortexResult<ArrayRef> { ... }
fn encode(
&self,
input: &Canonical,
_like: Option<&dyn Array>,
) -> VortexResult<Option<ArrayRef>> { ... }
}
Expand description
Dyn-compatible VTable trait for a Vortex array encoding.
This trait provides extension points for arrays to implement various features of Vortex. It is split into multiple sub-traits to make it easier for consumers to break up the implementation, as well as to allow for optional implementation of certain features, for example compute functions.
Required Methods§
Sourcefn id(&self) -> EncodingId
fn id(&self) -> EncodingId
Return the ID for this encoding implementation.