public abstract class LayoutDecorator<V,E> extends Object implements Layout<V,E>, IterativeContext
| Constructor and Description |
|---|
LayoutDecorator(Layout<V,E> delegate)
Creates an instance backed by the specified
delegate. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
done() |
Layout<V,E> |
getDelegate() |
Graph<V,E> |
getGraph() |
Dimension |
getSize() |
void |
initialize()
Initializes fields in the node that may not have
been set during the constructor.
|
boolean |
isLocked(V v) |
void |
lock(V v,
boolean state)
Locks or unlocks the specified vertex.
|
void |
reset() |
void |
setDelegate(Layout<V,E> delegate) |
void |
setGraph(Graph<V,E> graph) |
void |
setInitializer(com.google.common.base.Function<V,Point2D> initializer) |
void |
setLocation(V v,
Point2D location)
Changes the layout coordinates of
v to location. |
void |
setSize(Dimension d) |
void |
step()
Advances one step.
|
Point2D |
transform(V v) |
public void step()
IterativeContextstep in interface IterativeContextpublic void initialize()
Layoutinitialize in interface Layout<V,E>public void setInitializer(com.google.common.base.Function<V,Point2D> initializer)
setInitializer in interface Layout<V,E>initializer - a function that specifies initial locations for all verticespublic void setLocation(V v, Point2D location)
Layoutv to location.setLocation in interface Layout<V,E>v - the vertex whose location is to be specifiedlocation - the coordinates of the specified locationpublic Dimension getSize()
public boolean done()
done in interface IterativeContexttrue if this iterative process is finished, and false otherwise.public void lock(V v, boolean state)
Layoutpublic boolean isLocked(V v)
public void setSize(Dimension d)
Copyright © 2016. All rights reserved.