Trait binary_tree::Node [] [src]

pub trait Node {
    type Value;
    fn left(&self) -> Option<&Self>;
    fn right(&self) -> Option<&Self>;
    fn value(&self) -> &Self::Value;

    fn walk<'a, F>(&'a self, step_in: F)
    where
        F: FnMut(&'a Self) -> WalkAction
, { ... } }

Generic methods for traversing a binary tree.

Associated Types

Required Methods

Get a reference to the left subtree

Get a reference to the right subtree

Returns the value of the current node.

Provided Methods

Walk down the tree

Implementors