Trait ValueToStore

Source
pub trait ValueToStore {
    // Required methods
    fn encode(
        &self,
        shape: &Shape,
        store: &mut Vec<ColumnValue>,
        cache: &mut ColumnCacheWriter,
    );
    fn decode(
        shape: &Shape,
        store: &mut Vec<usize>,
        cache: &mut ColumnCacheReader,
    ) -> Self;
}
Expand description

Encode/Decode a Value to the column cache with a Shape describing how to store

Required Methods§

Source

fn encode( &self, shape: &Shape, store: &mut Vec<ColumnValue>, cache: &mut ColumnCacheWriter, )

Encode the value into the store

Source

fn decode( shape: &Shape, store: &mut Vec<usize>, cache: &mut ColumnCacheReader, ) -> Self

Decode the value from the store

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl ValueToStore for Value

Source§

fn encode( &self, shape: &Shape, store: &mut Vec<ColumnValue>, cache: &mut ColumnCacheWriter, )

Source§

fn decode( shape: &Shape, store: &mut Vec<usize>, cache: &mut ColumnCacheReader, ) -> Self

Implementors§