Tree iterator is a convinient and easy-to-use tree-traversing Java utility suitable for any kind of tree. It employs pre-order tree traversal algorithm (node is processed before its children). Two things set the tree iterator apart from a traditional way of traversing a treelike structure:
javax.swing.tree.TreeNode
) are provided with the iterator.Tree iterator was featured in the “Generic tree traversal” article in the November, 2000 issue of Doctor Dobb’s Journal.
Tree iterator is available under BSD license.