// List of Edges connecting nodes in trees - // designed to facilitate rotation operations // where an edge must be re-linked to new start and end nodes package ciips.animation.tree; import java.awt.*; import java.lang.*; import java.util.*; import ciips.animation.*; public class TreeEdgeList extends Vector implements DrawingObj { private static final int MIN_EDGES = 10; private static final boolean DEBUG = false; public TreeEdgeList( ) { super( MIN_EDGES ); if( DEBUG ) System.out.println("TreeEdgeList - constructed"); } public void reLink( TreeNode old_start, TreeNode new_start, TreeNode new_end ) { TreeEdge t; int n = size(); for( int k=0;k (" + new_start + "-" + new_end + ")" ); return; } } System.out.println( "TreeEdgeList:reLink - start (" + old_start + ") not found" ); } public int getY() { return 0; } public int getX() { return 0; } public void move( int x, int y ) { } public void setHighlight( boolean on ) {} public void setGrey( boolean on ) {} public void draw( Graphics g ) { int n = size(); if ( DEBUG ) System.out.println("TreeEdgeList:draw " + n + " edges"); for( int k=0;k