Trait mz_durable_cache::DurableCacheCodec
source · pub trait DurableCacheCodec: Debug + Eq {
type Key: Ord + Hash + Clone + Debug;
type Val: Eq + Debug;
type KeyCodec: Codec + Ord + Debug + Clone;
type ValCodec: Codec + Ord + Debug + Clone;
// Required methods
fn schemas( ) -> (<Self::KeyCodec as Codec>::Schema, <Self::ValCodec as Codec>::Schema);
fn encode(
key: &Self::Key,
val: &Self::Val,
) -> (Self::KeyCodec, Self::ValCodec);
fn decode(
key: &Self::KeyCodec,
val: &Self::ValCodec,
) -> (Self::Key, Self::Val);
}
Required Associated Types§
type Key: Ord + Hash + Clone + Debug
type Val: Eq + Debug
type KeyCodec: Codec + Ord + Debug + Clone
type ValCodec: Codec + Ord + Debug + Clone
Required Methods§
fn schemas() -> (<Self::KeyCodec as Codec>::Schema, <Self::ValCodec as Codec>::Schema)
fn encode(key: &Self::Key, val: &Self::Val) -> (Self::KeyCodec, Self::ValCodec)
fn decode(key: &Self::KeyCodec, val: &Self::ValCodec) -> (Self::Key, Self::Val)
Object Safety§
This trait is not object safe.