Class CachingLayout<V,E>
- java.lang.Object
-
- edu.uci.ics.jung.algorithms.layout.LayoutDecorator<V,E>
-
- edu.uci.ics.jung.visualization.layout.CachingLayout<V,E>
-
- All Implemented Interfaces:
edu.uci.ics.jung.algorithms.layout.Layout<V,E>
,edu.uci.ics.jung.algorithms.util.IterativeContext
,Caching
,org.apache.commons.collections4.Transformer<V,java.awt.geom.Point2D>
public class CachingLayout<V,E> extends edu.uci.ics.jung.algorithms.layout.LayoutDecorator<V,E> implements Caching
A LayoutDecorator that caches locations in a clearable Map. This can be used to ensure that edge endpoints are always the same as vertex locations when they are drawn in the render loop during the time that the layout's relaxer thread is changing the locations.- See Also:
LayoutDecorator
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Map<V,java.awt.geom.Point2D>
locationMap
-
Constructor Summary
Constructors Constructor Description CachingLayout(edu.uci.ics.jung.algorithms.layout.Layout<V,E> delegate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
clear cachevoid
init()
ititialize resources for a cachevoid
setGraph(edu.uci.ics.jung.graph.Graph<V,E> graph)
java.awt.geom.Point2D
transform(V v)
-
-
-
Field Detail
-
locationMap
protected java.util.Map<V,java.awt.geom.Point2D> locationMap
-
-