anl.aida.viz
Class ScaledNodeStyler
java.lang.Object
anl.aida.viz.AbstractCircleNodeStyler
anl.aida.viz.ScaledNodeStyler
- All Implemented Interfaces:
- NodeStyler
public class ScaledNodeStyler
- extends AbstractCircleNodeStyler
Node style implementation that scales the size of the ellipse
with respect to some intial size and document count. If a term node's
document count is equal to the base initial count then the node
will be the same as the original size. If the count is less than
the initial count then the size will be smaller than the initial
size and so on.
Field Summary |
private java.util.Map<java.lang.String,anl.aida.util.Pair<java.lang.Float,java.lang.Float>> |
sizeMap
|
Constructor Summary |
ScaledNodeStyler(java.awt.Paint nodePaint,
java.awt.Paint textPaint,
edu.umd.cs.piccolo.PLayer layer)
Layer is expected to contain PNodes with TermNode objects. |
Method Summary |
float |
getSize(TermNode tNode)
Gets the size appropriate for the specified term node. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
sizeMap
private java.util.Map<java.lang.String,anl.aida.util.Pair<java.lang.Float,java.lang.Float>> sizeMap
ScaledNodeStyler
public ScaledNodeStyler(java.awt.Paint nodePaint,
java.awt.Paint textPaint,
edu.umd.cs.piccolo.PLayer layer)
- Layer is expected to contain PNodes with TermNode objects.
- Parameters:
nodePaint
- the node painttextPaint
- the text paintlayer
- the layer containing the PNodes whose sizes will be
used as a base.
getSize
public float getSize(TermNode tNode)
- Gets the size appropriate for the specified term node.
- Parameters:
tNode
- the node to get the size for
- Returns:
- the size appropriate for the specified term node.