Class CachingEdgeRenderer<V,E>
- java.lang.Object
-
- edu.uci.ics.jung.visualization.renderers.BasicEdgeRenderer<V,E>
-
- edu.uci.ics.jung.visualization.renderers.CachingEdgeRenderer<V,E>
-
- All Implemented Interfaces:
LayoutChangeListener<V,E>
,Renderer.Edge<V,E>
,java.util.EventListener
,javax.swing.event.ChangeListener
public class CachingEdgeRenderer<V,E> extends BasicEdgeRenderer<V,E> implements javax.swing.event.ChangeListener, LayoutChangeListener<V,E>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface edu.uci.ics.jung.visualization.renderers.Renderer.Edge
Renderer.Edge.NOOP
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Set<E>
dirtyEdges
protected java.util.Map<E,java.awt.Shape>
edgeShapeMap
-
Fields inherited from class edu.uci.ics.jung.visualization.renderers.BasicEdgeRenderer
edgeArrowRenderingSupport
-
-
Constructor Summary
Constructors Constructor Description CachingEdgeRenderer(BasicVisualizationServer<V,E> vv)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
drawSimpleEdge(RenderContext<V,E> rc, Layout<V,E> layout, E e)
Draws the edgee
, whose endpoints are at(x1,y1)
and(x2,y2)
, on the graphics contextg
.void
layoutChanged(LayoutEvent<V,E> evt)
void
stateChanged(javax.swing.event.ChangeEvent evt)
-
Methods inherited from class edu.uci.ics.jung.visualization.renderers.BasicEdgeRenderer
getEdgeArrowRenderingSupport, paintEdge, prepareFinalEdgeShape, setEdgeArrowRenderingSupport
-
-
-
-
Constructor Detail
-
CachingEdgeRenderer
public CachingEdgeRenderer(BasicVisualizationServer<V,E> vv)
-
-
Method Detail
-
drawSimpleEdge
protected void drawSimpleEdge(RenderContext<V,E> rc, Layout<V,E> layout, E e)
Draws the edgee
, whose endpoints are at(x1,y1)
and(x2,y2)
, on the graphics contextg
. TheShape
provided by theEdgeShapeFunction
instance is scaled in the x-direction so that its width is equal to the distance between(x1,y1)
and(x2,y2)
.- Overrides:
drawSimpleEdge
in classBasicEdgeRenderer<V,E>
- Parameters:
rc
- the render context used for rendering the edgelayout
- the layout instance which provides the edge's endpoints' coordinatese
- the edge to be drawn
-
stateChanged
public void stateChanged(javax.swing.event.ChangeEvent evt)
- Specified by:
stateChanged
in interfacejavax.swing.event.ChangeListener
-
layoutChanged
public void layoutChanged(LayoutEvent<V,E> evt)
- Specified by:
layoutChanged
in interfaceLayoutChangeListener<V,E>
-
-