src
Class TreeLayout

java.lang.Object
  extended by src.Display
      extended by src.TreeLayout

public class TreeLayout
extends Display


Field Summary
 int CIRCLE_ARROW_RADIUS
           
 int FONT_SIZE
           
 GraphicPanel graphicPanel
           
 int H_SPACE
           
 int HALF_HEIGHT
           
 int HALF_WIDTH
           
 int HEIGHT
           
 VisNode levelTree
           
 int maxFrequency
           
 java.util.ArrayList<VisNode> movedNodes
           
 PFont myFont
           
 int ORIGIN_CIRCLE_ARROW_RADIUS
           
 int ORIGIN_FONT_SIZE
           
 int ORIGIN_H_SPACE
           
 int ORIGIN_HALF_HEIGHT
           
 int ORIGIN_HALF_WIDTH
           
 int ORIGIN_HEIGHT
           
 int ORIGIN_PARENT_HEIGHT
           
 int ORIGIN_PARENT_WIDTH
           
 int ORIGIN_RECT_HEIGHT
           
 int ORIGIN_RECT_WIDTH
           
 int ORIGIN_V_SPACE
           
 int ORIGIN_WIDTH
           
 int PARENT_HEIGHT
           
 int PARENT_WIDTH
           
 int RECT_HEIGHT
           
 int RECT_WIDTH
           
 double Scale
           
 int V_SPACE
           
 VisNode visTree
           
 int WIDTH
           
 
Constructor Summary
TreeLayout(VisNode visTree, GraphicPanel graphicPanel)
           
 
Method Summary
 void addMovementRecord(VisNode lowNode, VisNode highNode, java.util.Hashtable<VisNode,int[]> movementRecords, boolean moveUp)
          Start of animation computation
 int branchPatternMatch(java.util.ArrayList<VisNode> nextLowBranch, java.util.ArrayList<VisNode> nextHighBranch)
           
 java.util.Hashtable<VisNode,int[]> computeMoves(VisNode visRoot, VisNode futureRoot, boolean moveUp)
           
 boolean contains(int x1, int y1, int x2, int y2, int HALF_WIDTH, int HALF_HEIGHT)
           
 void display(VisNode root)
           
 void drawExpandedNode(VisNode node, double scaleVar)
           
 VisNode getClickedNode(VisNode visNode, int mouseX, int mouseY)
           
 void movementProcess(java.util.ArrayList<VisNode> nextLowBranch, java.util.ArrayList<VisNode> nextHighBranch, java.util.Hashtable<VisNode,int[]> movementRecords, boolean moveUp)
           
 void recursiveDisplay(VisNode node)
           
 void recursiveRelocation(VisNode node)
          Calculates the new location of the nodes
 int structureAggregation(VisNode node)
           
 void zoomin()
          End of animation computation
 void zoomout()
           
 
Methods inherited from class src.Display
getScaleVar
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

myFont

public PFont myFont

Scale

public double Scale

ORIGIN_FONT_SIZE

public int ORIGIN_FONT_SIZE

ORIGIN_H_SPACE

public int ORIGIN_H_SPACE

ORIGIN_V_SPACE

public int ORIGIN_V_SPACE

ORIGIN_WIDTH

public int ORIGIN_WIDTH

ORIGIN_HEIGHT

public int ORIGIN_HEIGHT

ORIGIN_HALF_WIDTH

public int ORIGIN_HALF_WIDTH

ORIGIN_HALF_HEIGHT

public int ORIGIN_HALF_HEIGHT

ORIGIN_RECT_HEIGHT

public int ORIGIN_RECT_HEIGHT

ORIGIN_RECT_WIDTH

public int ORIGIN_RECT_WIDTH

ORIGIN_PARENT_WIDTH

public int ORIGIN_PARENT_WIDTH

ORIGIN_PARENT_HEIGHT

public int ORIGIN_PARENT_HEIGHT

ORIGIN_CIRCLE_ARROW_RADIUS

public int ORIGIN_CIRCLE_ARROW_RADIUS

H_SPACE

public int H_SPACE

V_SPACE

public int V_SPACE

visTree

public VisNode visTree

graphicPanel

public GraphicPanel graphicPanel

movedNodes

public java.util.ArrayList<VisNode> movedNodes

levelTree

public VisNode levelTree

FONT_SIZE

public int FONT_SIZE

WIDTH

public int WIDTH

HEIGHT

public int HEIGHT

HALF_WIDTH

public int HALF_WIDTH

HALF_HEIGHT

public int HALF_HEIGHT

RECT_HEIGHT

public int RECT_HEIGHT

RECT_WIDTH

public int RECT_WIDTH

PARENT_WIDTH

public int PARENT_WIDTH

PARENT_HEIGHT

public int PARENT_HEIGHT

CIRCLE_ARROW_RADIUS

public int CIRCLE_ARROW_RADIUS

maxFrequency

public int maxFrequency
Constructor Detail

TreeLayout

public TreeLayout(VisNode visTree,
                  GraphicPanel graphicPanel)
Method Detail

display

public void display(VisNode root)
Overrides:
display in class Display

structureAggregation

public int structureAggregation(VisNode node)

getClickedNode

public VisNode getClickedNode(VisNode visNode,
                              int mouseX,
                              int mouseY)
Overrides:
getClickedNode in class Display

contains

public boolean contains(int x1,
                        int y1,
                        int x2,
                        int y2,
                        int HALF_WIDTH,
                        int HALF_HEIGHT)

drawExpandedNode

public void drawExpandedNode(VisNode node,
                             double scaleVar)

recursiveRelocation

public void recursiveRelocation(VisNode node)
Calculates the new location of the nodes

Parameters:
node -

recursiveDisplay

public void recursiveDisplay(VisNode node)

addMovementRecord

public void addMovementRecord(VisNode lowNode,
                              VisNode highNode,
                              java.util.Hashtable<VisNode,int[]> movementRecords,
                              boolean moveUp)
Start of animation computation


branchPatternMatch

public int branchPatternMatch(java.util.ArrayList<VisNode> nextLowBranch,
                              java.util.ArrayList<VisNode> nextHighBranch)

movementProcess

public void movementProcess(java.util.ArrayList<VisNode> nextLowBranch,
                            java.util.ArrayList<VisNode> nextHighBranch,
                            java.util.Hashtable<VisNode,int[]> movementRecords,
                            boolean moveUp)

computeMoves

public java.util.Hashtable<VisNode,int[]> computeMoves(VisNode visRoot,
                                                       VisNode futureRoot,
                                                       boolean moveUp)
Overrides:
computeMoves in class Display

zoomin

public void zoomin()
End of animation computation

Overrides:
zoomin in class Display

zoomout

public void zoomout()
Overrides:
zoomout in class Display