Trait ArrayEncoding

Source
pub trait ArrayEncoding:
    'static
    + Sync
    + Send
    + Debug {
    // Required methods
    fn id(&self) -> EncodingId;
    fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>;
    fn with_dyn(
        &self,
        array: &Array,
        f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>,
    ) -> Result<(), VortexError>;
}
Expand description

Object-safe encoding trait for an array.

Required Methods§

Source

fn id(&self) -> EncodingId

Source

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Flatten the given array.

Source

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Unwrap the provided array into an implementation of ArrayTrait

Trait Implementations§

Source§

impl Hash for dyn ArrayEncoding + '_

Source§

fn hash<H>(&self, state: &mut H)
where H: Hasher,

Feeds this value into the given Hasher. Read more
Source§

impl PartialEq for dyn ArrayEncoding + '_

Source§

fn eq(&self, other: &dyn ArrayEncoding) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Eq for dyn ArrayEncoding + '_

Implementations on Foreign Types§

Source§

impl ArrayEncoding for ALPEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for ALPRDEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for ByteBoolEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for DateTimePartsEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for DictEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for BitPackedEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for DeltaEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for FoREncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for FSSTEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for RoaringBoolEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for RoaringIntEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for RunEndBoolEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for RunEndEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Source§

impl ArrayEncoding for ZigZagEncoding

Source§

fn id(&self) -> EncodingId

Source§

fn canonicalize(&self, array: Array) -> Result<Canonical, VortexError>

Source§

fn with_dyn( &self, array: &Array, f: &mut dyn for<'b> FnMut(&'b dyn ArrayTrait) -> Result<(), VortexError>, ) -> Result<(), VortexError>

Implementors§