pub enum TrieKinds<'db, L: TrieLayout> {
Generic(TrieDB<'db, L>),
Secure(SecTrieDB<'db, L>),
Fat(FatDB<'db, L>),
}
Expand description
All different kinds of tries. This is used to prevent a heap allocation for every created trie.
Variants
Generic(TrieDB<'db, L>)
A generic trie db.
Secure(SecTrieDB<'db, L>)
A secure trie db.
Fat(FatDB<'db, L>)
A fat trie db.
Trait Implementations
sourceimpl<'db, L: TrieLayout> Trie<L> for TrieKinds<'db, L>
impl<'db, L: TrieLayout> Trie<L> for TrieKinds<'db, L>
sourcefn contains(&self, key: &[u8]) -> Result<bool, TrieHash<L>, CError<L>>
fn contains(&self, key: &[u8]) -> Result<bool, TrieHash<L>, CError<L>>
Does the trie contain a given key?
sourcefn get_with<'a, 'key, Q: Query<L::Hash>>(
&'a self,
key: &'key [u8],
query: Q
) -> Result<Option<Q::Item>, TrieHash<L>, CError<L>> where
'a: 'key,
fn get_with<'a, 'key, Q: Query<L::Hash>>(
&'a self,
key: &'key [u8],
query: Q
) -> Result<Option<Q::Item>, TrieHash<L>, CError<L>> where
'a: 'key,
Search for the key with the given query parameter. See the docs of the Query
trait for more details. Read more
Auto Trait Implementations
impl<'db, L> !RefUnwindSafe for TrieKinds<'db, L>
impl<'db, L> !Send for TrieKinds<'db, L>
impl<'db, L> !Sync for TrieKinds<'db, L>
impl<'db, L> Unpin for TrieKinds<'db, L>
impl<'db, L> !UnwindSafe for TrieKinds<'db, L>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more