Enum trie_db::node::NodeHandlePlan
source · [−]Expand description
A NodeHandlePlan
is a decoding plan for constructing a NodeHandle
from an encoded trie
node. This is used as a substructure of NodePlan
. See NodePlan
for details.
Variants
Hash(Range<usize>)
Inline(Range<usize>)
Implementations
sourceimpl NodeHandlePlan
impl NodeHandlePlan
sourcepub fn build<'a, 'b>(&'a self, data: &'b [u8]) -> NodeHandle<'b>
pub fn build<'a, 'b>(&'a self, data: &'b [u8]) -> NodeHandle<'b>
Build a node handle by decoding a byte slice according to the node handle plan. It is the responsibility of the caller to ensure that the node plan was created for the argument data, otherwise the call may decode incorrectly or panic.
Trait Implementations
sourceimpl Clone for NodeHandlePlan
impl Clone for NodeHandlePlan
sourcefn clone(&self) -> NodeHandlePlan
fn clone(&self) -> NodeHandlePlan
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for NodeHandlePlan
impl Debug for NodeHandlePlan
sourceimpl PartialEq<NodeHandlePlan> for NodeHandlePlan
impl PartialEq<NodeHandlePlan> for NodeHandlePlan
sourcefn eq(&self, other: &NodeHandlePlan) -> bool
fn eq(&self, other: &NodeHandlePlan) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &NodeHandlePlan) -> bool
fn ne(&self, other: &NodeHandlePlan) -> bool
This method tests for !=
.
impl Eq for NodeHandlePlan
impl StructuralEq for NodeHandlePlan
impl StructuralPartialEq for NodeHandlePlan
Auto Trait Implementations
impl RefUnwindSafe for NodeHandlePlan
impl Send for NodeHandlePlan
impl Sync for NodeHandlePlan
impl Unpin for NodeHandlePlan
impl UnwindSafe for NodeHandlePlan
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
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more