| | | | | |

A Binary Search Tree Class - Composition

Analogous to implementation of Ordered List

  template <typename T, class P = LessThan<T> >
  class BST
  {
  public:
    typedef T                                        ValueType; 
    typedef P                                        PredicateType;
    typedef BSTNavigator < T , P >                   Navigator;
    typedef BinaryTreeInorderIterator < Navigator >  Iterator;
    ...
  protected:
    BinaryTree<T> tree_;
    PredicateType pred_;
  };

| | Top of Page | 12. Binary Search Trees - 5 of 27