public class ObservableCachingLayout<V,E> extends LayoutDecorator<V,E> implements ChangeEventSupport, Caching
LayoutDecorator| Modifier and Type | Field and Description |
|---|---|
protected ChangeEventSupport |
changeSupport |
protected Map<V,Point2D> |
locationMap |
delegate| Constructor and Description |
|---|
ObservableCachingLayout(Layout<V,E> delegate) |
| Modifier and Type | Method and Description |
|---|---|
void |
addChangeListener(ChangeListener l) |
void |
clear()
clear cache
|
boolean |
done()
Returns true if this iterative process is finished, and false otherwise.
|
void |
fireStateChanged() |
ChangeListener[] |
getChangeListeners()
Returns an array of all the
ChangeListeners added
with addChangeListener(). |
void |
init()
ititialize resources for a cache
|
void |
initialize()
Initializes fields in the node that may not have
been set during the constructor.
|
void |
removeChangeListener(ChangeListener l)
Removes a ChangeListener.
|
void |
setGraph(Graph<V,E> graph)
setter for graph
|
void |
setLocation(V v,
Point2D location)
set the location of a vertex
|
void |
step()
Advances one step.
|
Point2D |
transform(V v) |
getDelegate, getGraph, getSize, isLocked, lock, reset, setDelegate, setInitializer, setSizeprotected ChangeEventSupport changeSupport
public void step()
IterativeContextstep in interface IterativeContextstep in class LayoutDecorator<V,E>edu.uci.ics.jung.algorithms.layout.Layout#step()public void initialize()
Layoutinitialize in interface Layout<V,E>initialize in class LayoutDecorator<V,E>Layout.initialize()public boolean done()
IterativeContextdone in interface IterativeContextdone in class LayoutDecorator<V,E>IterativeContext.done()public void setLocation(V v, Point2D location)
LayoutsetLocation in interface Layout<V,E>setLocation in class LayoutDecorator<V,E>v - location - Layout.setLocation(java.lang.Object, java.awt.geom.Point2D)public void addChangeListener(ChangeListener l)
addChangeListener in interface ChangeEventSupportpublic void removeChangeListener(ChangeListener l)
ChangeEventSupportremoveChangeListener in interface ChangeEventSupportl - the listener to be removedpublic ChangeListener[] getChangeListeners()
ChangeEventSupportChangeListeners added
with addChangeListener().getChangeListeners in interface ChangeEventSupportChangeListeners added or an empty
array if no listeners have been addedpublic void fireStateChanged()
fireStateChanged in interface ChangeEventSupportpublic void setGraph(Graph<V,E> graph)
Layoutpublic void clear()
Cachingpublic void init()
CachingCopyright © 2015. All rights reserved.