public class FRLayout<V,E> extends AbstractLayout<V,E> implements IterativeContext
Behavior is determined by the following settable parameters:
Modifier and Type | Class and Description |
---|---|
protected static class |
FRLayout.FRVertexData |
Modifier and Type | Field and Description |
---|---|
protected com.google.common.cache.LoadingCache<V,FRLayout.FRVertexData> |
frVertexData |
graph, initialized, locations, size
Constructor and Description |
---|
FRLayout(Graph<V,E> g) |
FRLayout(Graph<V,E> g,
Dimension d) |
Modifier and Type | Method and Description |
---|---|
protected void |
calcAttraction(E e) |
protected void |
calcPositions(V v) |
protected void |
calcRepulsion(V v1) |
boolean |
done() |
protected FRLayout.FRVertexData |
getFRData(V v) |
void |
initialize()
Initializes fields in the node that may not have
been set during the constructor.
|
boolean |
isIncremental() |
void |
reset() |
void |
setAttractionMultiplier(double attraction) |
void |
setMaxIterations(int maxIterations) |
void |
setRepulsionMultiplier(double repulsion) |
void |
setSize(Dimension size)
When a visualization is resized, it presumably wants to fix the
locations of the vertices and possibly to reinitialize its data.
|
void |
step()
Moves the iteration forward one notch, calculation attraction and
repulsion between vertices and edges and cooling the temperature.
|
apply, getGraph, getSize, getX, getY, isLocked, lock, lock, offsetVertex, setGraph, setInitializer, setLocation, setLocation
protected com.google.common.cache.LoadingCache<V,FRLayout.FRVertexData> frVertexData
public void setSize(Dimension size)
AbstractLayout
public void setAttractionMultiplier(double attraction)
public void setRepulsionMultiplier(double repulsion)
public void initialize()
Layout
initialize
in interface Layout<V,E>
public void step()
step
in interface IterativeContext
protected void calcPositions(V v)
protected void calcAttraction(E e)
protected void calcRepulsion(V v1)
public void setMaxIterations(int maxIterations)
protected FRLayout.FRVertexData getFRData(V v)
public boolean isIncremental()
public boolean done()
done
in interface IterativeContext
Copyright © 2015. All rights reserved.