Rust version of flat-tree. A series of functions to map a binary tree to a list
extern crate flat_tree;
let parent = flat_tree::parent(0);
println!("parent of 0 is {}", parent);
Returns the flat-tree of the tree node at the specified depth and offset
Returns the depth of a node
Returns the offset of a node
Returns the parent of a node
Returns the sibling of a node
Returns the parent's sibling of a node
Returns both children of a node.
Returns only the left child of a node
Returns only the right child of a node
Returns the right most node in the tree that i spans
Returns the left most node in the tree that i spans
Returns the left and right most nodes in the tree that i spans
Returns how many nodes are in the tree that the node spans
Returns all the previous fully rooted trees before the node
MIT