updated HeapTree.java