anl.aida.bubble
Class DefaultBubbleRenderer

java.lang.Object
  extended by anl.aida.bubble.DefaultBubbleRenderer

public class DefaultBubbleRenderer
extends java.lang.Object


Field Summary
static long ANIM_DURATION
           
private  java.util.Map<java.lang.Integer,Bubble> bubbles
           
private  edu.umd.cs.piccolo.PLayer layer
           
private static int MAX_BUBBLE_SIZE
           
private  int selectedCount
           
 
Constructor Summary
DefaultBubbleRenderer(BubbleDataset dataset, BubbleTooltip tooltip)
           
 
Method Summary
 void addLayers(edu.umd.cs.piccolo.PNode parent)
           
 java.awt.Color[] generateColors(int n)
           
 void selectBubble(int categoryIndex, boolean selected)
          Selects or unselects the bubble with the specified category index.
 void setNodeVisible(int category, boolean visible)
           
 edu.umd.cs.piccolo.PNode update(int category, float px, float py, double scale)
           
 edu.umd.cs.piccolo.PNode updateAnimate(int category, float px, float py, double scale)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ANIM_DURATION

public static final long ANIM_DURATION
See Also:
Constant Field Values

MAX_BUBBLE_SIZE

private static final int MAX_BUBBLE_SIZE
See Also:
Constant Field Values

bubbles

private java.util.Map<java.lang.Integer,Bubble> bubbles

layer

private edu.umd.cs.piccolo.PLayer layer

selectedCount

private int selectedCount
Constructor Detail

DefaultBubbleRenderer

public DefaultBubbleRenderer(BubbleDataset dataset,
                             BubbleTooltip tooltip)
Method Detail

generateColors

public java.awt.Color[] generateColors(int n)

selectBubble

public void selectBubble(int categoryIndex,
                         boolean selected)
Selects or unselects the bubble with the specified category index.

Parameters:
categoryIndex - in the index of the bubble
selected - whether or not the bubble is selected or unselected.

addLayers

public void addLayers(edu.umd.cs.piccolo.PNode parent)

update

public edu.umd.cs.piccolo.PNode update(int category,
                                       float px,
                                       float py,
                                       double scale)

updateAnimate

public edu.umd.cs.piccolo.PNode updateAnimate(int category,
                                              float px,
                                              float py,
                                              double scale)

setNodeVisible

public void setNodeVisible(int category,
                           boolean visible)