[go: up one dir, main page]

Trait Config

Source
pub trait Config {
    type Payload: Clone + Borrow<Self::Key> + 'static;
    type Key: Hash + Eq;
}
Expand description

Customization of the Raw.

This specifies how the trie should act. Maybe some more customization will be possible in the future, but for now this allows tweaking what in how is stored.

Required Associated Types§

Source

type Payload: Clone + Borrow<Self::Key> + 'static

The payload (eg. values) stored inside the trie.

Source

type Key: Hash + Eq

Each payload must contain a key as its part. This is the type for the key, which is used for hashing and identification of values in the tree.

Implementors§

Source§

impl<T> Config for Trivial<T>
where T: Clone + Hash + Eq + 'static,

Source§

type Payload = T

Source§

type Key = T