Struct reference_trie::TestTrieCache
source · pub struct TestTrieCache<L: TrieLayout> { /* private fields */ }
Expand description
Example trie cache implementation.
Should not be used for anything in production.
Implementations§
source§impl<L: TrieLayout> TestTrieCache<L>
impl<L: TrieLayout> TestTrieCache<L>
sourcepub fn clear_value_cache(&mut self)
pub fn clear_value_cache(&mut self)
Clear the value cache.
sourcepub fn clear_node_cache(&mut self)
pub fn clear_node_cache(&mut self)
Clear the node cache.
Trait Implementations§
source§impl<L: TrieLayout> Default for TestTrieCache<L>
impl<L: TrieLayout> Default for TestTrieCache<L>
source§impl<L: TrieLayout> TrieCache<<L as TrieLayout>::Codec> for TestTrieCache<L>
impl<L: TrieLayout> TrieCache<<L as TrieLayout>::Codec> for TestTrieCache<L>
source§fn lookup_value_for_key(
&mut self,
key: &[u8]
) -> Option<&CachedValue<TrieHash<L>>>
fn lookup_value_for_key( &mut self, key: &[u8] ) -> Option<&CachedValue<TrieHash<L>>>
Lookup value for the given
key
. Read more