All Packages Class Hierarchy This Package Previous Next Index
Class jdsl.core.ref.RestructurableNodeBinaryTree
java.lang.Object
|
+----jdsl.core.ref.BTNodeBinaryTree
|
+----jdsl.core.ref.RestructurableNodeBinaryTree
- public class RestructurableNodeBinaryTree
- extends BTNodeBinaryTree
- implements RestructurableBinaryTree
A BinaryTree
that supports restructuring.
- Version:
- $Revision: 1.2 $, $Date: 1998/06/30 20:58:43 $
- Author:
- Ming-En Cho (mec), Mike Boilen (mgb)
-
RestructurableNodeBinaryTree()
- Construct a new restructurable binary tree.
-
newContainer()
- Returns a new
RestructurableNodeBinaryTree.
-
restructure(Position)
- Restructures the tree at a given position.
RestructurableNodeBinaryTree
public RestructurableNodeBinaryTree()
- Construct a new restructurable binary tree.
restructure
public Position restructure(Position grandchild) throws BoundaryViolationException, InvalidPositionException
- Restructures the tree at a given position.
- Parameters:
- grandchild - The position to rotate at.
- Throws: BoundaryViolationException
- if grandchild does not have a grand
parent.
- Throws: InvalidPositionException
- if
grandchild
is
external.
newContainer
public Container newContainer()
- Returns a new
RestructurableNodeBinaryTree.
- Returns:
- a RestructurableNodeBinaryTree
- Overrides:
- newContainer in class BTNodeBinaryTree
All Packages Class Hierarchy This Package Previous Next Index