Struct TreeSlice

Source
pub struct TreeSlice<N> { /* private fields */ }
Expand description

Each subtree is contigious in memory and can borrowed independently similarly to a slice of bytes.

Implementations§

Source§

impl<N> TreeSlice<N>

Source

pub fn from_slice(slice: &[u8]) -> &Self

Source

pub fn read_node(&self) -> (N::Value, Branches<'_, N>)
where N: Node,

Deserializes the value of the root node of this silce, and returns an iterator over its children.

Auto Trait Implementations§

§

impl<N> Freeze for TreeSlice<N>

§

impl<N> RefUnwindSafe for TreeSlice<N>
where N: RefUnwindSafe,

§

impl<N> Send for TreeSlice<N>
where N: Send,

§

impl<N> !Sized for TreeSlice<N>

§

impl<N> Sync for TreeSlice<N>
where N: Sync,

§

impl<N> Unpin for TreeSlice<N>
where N: Unpin,

§

impl<N> UnwindSafe for TreeSlice<N>
where N: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more