[−][src]Struct xtree::CursorMut
A mutable Cursor can freely visit node in tree
Implementations
impl<'a, T> CursorMut<'a, T>
[src]
pub fn move_child(&mut self, at: usize)
[src]
pub fn move_parent(&mut self)
[src]
move this cursor to its parent. Do nothing if it is already in the root node.
pub fn move_root(&mut self)
[src]
Move this cursor to its root. Do nothing if it is already in the root node.
pub fn current(&self) -> &'a mut T
[src]
Return the reference to the current
pub fn children_count(&self) -> usize
[src]
Get the count of children in current node
pub fn children(&self) -> ChildrenIterMut<'a, T>ⓘNotable traits for ChildrenIterMut<'a, T>
impl<'a, T> Iterator for ChildrenIterMut<'a, T> type Item = &'a mut T;
[src]
Notable traits for ChildrenIterMut<'a, T>
impl<'a, T> Iterator for ChildrenIterMut<'a, T> type Item = &'a mut T;
Get a immutable children iterator
pub fn is_root(&self) -> bool
[src]
Return true if current node is the root
pub fn is_leaf(&self) -> bool
[src]
Return true if current node is a leaf
pub fn remove(self) -> Option<Tree<T>>
[src]
Remove a sub-tree and consume the cursor
return None when current node is root
pub fn add_child(&mut self, tree: Tree<T>)
[src]
Add a sub-tree to children of current node
Auto Trait Implementations
impl<'a, T> RefUnwindSafe for CursorMut<'a, T> where
T: RefUnwindSafe,
[src]
T: RefUnwindSafe,
impl<'a, T> !Send for CursorMut<'a, T>
[src]
impl<'a, T> !Sync for CursorMut<'a, T>
[src]
impl<'a, T> Unpin for CursorMut<'a, T>
[src]
impl<'a, T> UnwindSafe for CursorMut<'a, T> where
T: RefUnwindSafe,
[src]
T: RefUnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,