sp_trie

Trait KeyFunction

Source
pub trait KeyFunction<H>
where H: Hasher,
{ type Key: Send + Sync + Clone + Hash + Eq + MaybeDebug + Ord; // Required method fn key(hash: &<H as Hasher>::Out, prefix: (&[u8], Option<u8>)) -> Self::Key; }
Expand description

Various re-exports from the memory-db crate.

Required Associated Types§

Required Methods§

Source

fn key(hash: &<H as Hasher>::Out, prefix: (&[u8], Option<u8>)) -> Self::Key

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.

Implementors§

Source§

impl<H> KeyFunction<H> for LegacyPrefixedKey<H>
where H: Hasher,

Source§

impl<H> KeyFunction<H> for HashKey<H>
where H: Hasher,

Source§

type Key = <H as Hasher>::Out

Source§

impl<H> KeyFunction<H> for PrefixedKey<H>
where H: Hasher,