IKeyExprTreeNodeMut

Trait IKeyExprTreeNodeMut 

Source
pub trait IKeyExprTreeNodeMut<Weight>: IKeyExprTreeNode<Weight> {
    // Required methods
    fn parent_mut(&mut self) -> Option<&mut Self::Parent>;
    fn weight_mut(&mut self) -> Option<&mut Weight>;
    fn take_weight(&mut self) -> Option<Weight>;
    fn insert_weight(&mut self, weight: Weight) -> Option<Weight>;
    fn children_mut(&mut self) -> &mut Self::Children;
}
Expand description

The mutating methods of a KeTree node.

Required Methods§

Source

fn parent_mut(&mut self) -> Option<&mut Self::Parent>

Mutably access the parent node if it exists (the node isn’t the first chunk of a key-expression).

Source

fn weight_mut(&mut self) -> Option<&mut Weight>

Mutably access the node’s weight.

Source

fn take_weight(&mut self) -> Option<Weight>

Remove the node’s weight.

Source

fn insert_weight(&mut self, weight: Weight) -> Option<Weight>

Assign a weight to the node, returning the previous weight if the node had one.

Source

fn children_mut(&mut self) -> &mut Self::Children

Mutably access the node’s children.

Implementations on Foreign Types§

Source§

impl<T: IKeyExprTreeNodeMut<Weight>, Weight> IKeyExprTreeNodeMut<Weight> for &mut T

Source§

fn parent_mut(&mut self) -> Option<&mut Self::Parent>

Source§

fn weight_mut(&mut self) -> Option<&mut Weight>

Source§

fn take_weight(&mut self) -> Option<Weight>

Source§

fn insert_weight(&mut self, weight: Weight) -> Option<Weight>

Source§

fn children_mut(&mut self) -> &mut Self::Children

Source§

impl<T: IKeyExprTreeNodeMut<Weight>, Weight> IKeyExprTreeNodeMut<Weight> for Box<T>

Source§

fn parent_mut(&mut self) -> Option<&mut Self::Parent>

Source§

fn weight_mut(&mut self) -> Option<&mut Weight>

Source§

fn take_weight(&mut self) -> Option<Weight>

Source§

fn insert_weight(&mut self, weight: Weight) -> Option<Weight>

Source§

fn children_mut(&mut self) -> &mut Self::Children

Source§

impl<T: IKeyExprTreeNodeMut<Weight>, Weight, Token: TokenTrait> IKeyExprTreeNodeMut<Weight> for (&Arc<TokenCell<T, Token>>, &mut Token)

Source§

fn parent_mut(&mut self) -> Option<&mut Self::Parent>

Source§

fn weight_mut(&mut self) -> Option<&mut Weight>

Source§

fn take_weight(&mut self) -> Option<Weight>

Source§

fn insert_weight(&mut self, weight: Weight) -> Option<Weight>

Source§

fn children_mut(&mut self) -> &mut Self::Children

Source§

impl<T: IKeyExprTreeNodeMut<Weight>, Weight, Token: TokenTrait> IKeyExprTreeNodeMut<Weight> for (&TokenCell<T, Token>, &mut Token)

Source§

fn parent_mut(&mut self) -> Option<&mut Self::Parent>

Source§

fn weight_mut(&mut self) -> Option<&mut Weight>

Source§

fn take_weight(&mut self) -> Option<Weight>

Source§

fn insert_weight(&mut self, weight: Weight) -> Option<Weight>

Source§

fn children_mut(&mut self) -> &mut Self::Children

Implementors§

Source§

impl<T: IKeyExprTreeNodeMut<Weight>, Weight, Token: TokenTrait> IKeyExprTreeNodeMut<Weight> for Tokenized<&Arc<TokenCell<T, Token>>, &mut Token>

Source§

impl<T: IKeyExprTreeNodeMut<Weight>, Weight, Token: TokenTrait> IKeyExprTreeNodeMut<Weight> for Tokenized<&TokenCell<T, Token>, &mut Token>

Source§

impl<Weight, Parent: IArcProvider, Wildness: IWildness, Children: IChildrenProvider<Arc<TokenCell<KeArcTreeNode<Weight, Weak<()>, Wildness, Children, Token>, Token>>>, Token: TokenTrait> IKeyExprTreeNodeMut<Weight> for KeArcTreeNode<Weight, Parent, Wildness, Children, Token>
where Children::Assoc: IChildren<Arc<TokenCell<KeArcTreeNode<Weight, Weak<()>, Wildness, Children, Token>, Token>>>,

Source§

impl<Weight, Wildness: IWildness, Children: IChildrenProvider<Box<Self>>> IKeyExprTreeNodeMut<Weight> for KeyExprTreeNode<Weight, Wildness, Children>
where Children::Assoc: IChildren<Box<Self>>,