Cover Data Structures and Algorithms with Object-Oriented Design Patterns in Java
next up previous contents index

Fields

To simplify the implementation of the algorithms, a parent field has been added. The parent field refers to the BTree node which is the parent of the given node. Whereas the subtree field of the MWayTree class allows an algorithm to move down the tree; the parent field admits movement up the tree. Since the root of a tree has no parent, the parent field of the root node is assigned the value null.


next up previous contents index

Bruno Copyright © 1998 by Bruno R. Preiss, P.Eng. All rights reserved.