Trait layout_2013::traversal::InorderFlowTraversal

source ·
pub trait InorderFlowTraversal {
    // Required method
    fn process(&mut self, flow: &mut dyn Flow, level: u32);

    // Provided methods
    fn should_process_subtree(&mut self, _flow: &mut dyn Flow) -> bool { ... }
    fn traverse(&mut self, flow: &mut dyn Flow, level: u32) { ... }
}
Expand description

An in-order (sequential only) traversal.

Required Methods§

source

fn process(&mut self, flow: &mut dyn Flow, level: u32)

The operation to perform. Returns the level of the tree we’re at.

Provided Methods§

source

fn should_process_subtree(&mut self, _flow: &mut dyn Flow) -> bool

Returns true if this node should be processed and false if neither this node nor its descendants should be processed.

source

fn traverse(&mut self, flow: &mut dyn Flow, level: u32)

Traverses the tree in-order.

Implementors§