Struct trie_db::TrieFactory
source · pub struct TrieFactory { /* private fields */ }
Expand description
Trie factory.
Implementations§
source§impl TrieFactory
impl TrieFactory
sourcepub fn readonly<'db, 'cache, L: TrieLayout>(
&self,
db: &'db dyn HashDBRef<L::Hash, DBValue>,
root: &'db TrieHash<L>
) -> TrieKinds<'db, 'cache, L>
pub fn readonly<'db, 'cache, L: TrieLayout>( &self, db: &'db dyn HashDBRef<L::Hash, DBValue>, root: &'db TrieHash<L> ) -> TrieKinds<'db, 'cache, L>
Create new immutable instance of Trie.
sourcepub fn create<'db, L: TrieLayout + 'db>(
&self,
db: &'db mut dyn HashDB<L::Hash, DBValue>,
root: &'db mut TrieHash<L>
) -> Box<dyn TrieMut<L> + 'db>
pub fn create<'db, L: TrieLayout + 'db>( &self, db: &'db mut dyn HashDB<L::Hash, DBValue>, root: &'db mut TrieHash<L> ) -> Box<dyn TrieMut<L> + 'db>
Create new mutable instance of Trie.
sourcepub fn from_existing<'db, L: TrieLayout + 'db>(
&self,
db: &'db mut dyn HashDB<L::Hash, DBValue>,
root: &'db mut TrieHash<L>
) -> Box<dyn TrieMut<L> + 'db>
pub fn from_existing<'db, L: TrieLayout + 'db>( &self, db: &'db mut dyn HashDB<L::Hash, DBValue>, root: &'db mut TrieHash<L> ) -> Box<dyn TrieMut<L> + 'db>
Create new mutable instance of trie and check for errors.
Trait Implementations§
source§impl Clone for TrieFactory
impl Clone for TrieFactory
source§fn clone(&self) -> TrieFactory
fn clone(&self) -> TrieFactory
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Default for TrieFactory
impl Default for TrieFactory
source§fn default() -> TrieFactory
fn default() -> TrieFactory
Returns the “default value” for a type. Read more