pub struct TreeZipper {
pub focus: TreeNodeExt,
pub context: Vec<(String, Vec<TreeNodeExt>, Vec<TreeNodeExt>)>,
}Expand description
A simple tree zipper for navigating trees.
Fields§
§focus: TreeNodeExtCurrent focus node
context: Vec<(String, Vec<TreeNodeExt>, Vec<TreeNodeExt>)>Context: (parent_label, left_siblings, right_siblings)
Implementations§
Source§impl TreeZipper
impl TreeZipper
Sourcepub fn new(tree: TreeNodeExt) -> Self
pub fn new(tree: TreeNodeExt) -> Self
Create a zipper from a tree.
Trait Implementations§
Source§impl Clone for TreeZipper
impl Clone for TreeZipper
Source§fn clone(&self) -> TreeZipper
fn clone(&self) -> TreeZipper
Returns a duplicate 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 moreAuto Trait Implementations§
impl Freeze for TreeZipper
impl RefUnwindSafe for TreeZipper
impl Send for TreeZipper
impl Sync for TreeZipper
impl Unpin for TreeZipper
impl UnsafeUnpin for TreeZipper
impl UnwindSafe for TreeZipper
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more