public void setLeft(BinaryNode <T> left) { this.left = left; }
public void setRight(BinaryNode <T> right) { this.right = right; }
public int Size() { return(BinaryNode <T> .Size(root)); }
public BinaryNode(T theElement, BinaryNode <T> left, BinaryNode <T> right) { this.element = theElement; this.left = left; this.right = right; }
public int CountNodesWithTwoChildren() { return(BinaryNode <T> .CountNodesWithTwoChildren(root)); }
public void MakeEmpty() { root = null; }
public int CountNodesWithOneChild() { return(BinaryNode <T> .CountNodesWithOneChild(root)); }
public int CountLeaves() { return(BinaryNode <T> .CountLeaves(root)); }
public int Height() { return(BinaryNode <T> .Height(root)); }
public BinaryTree(T rootItem) { root = new BinaryNode <T>(rootItem, null, null); }
public BinaryTree() { root = null; }