public interface Layout
Layout
interface to allow the
LayoutController
to run it properly.
See the LayoutBuilder
documentation to know how layout should
be instanciated.
To have fully integrated properties that can be changed in real-time by users,
properly define the various LayoutProperty
returned by the
getProperties()
method and provide getter and setter for each.
LayoutBuilder
Modifier and Type | Method and Description |
---|---|
boolean |
canAlgo()
Tests if the algorithm can run, called before each pass.
|
void |
endAlgo()
Called when the algorithm is finished (canAlgo() returns false).
|
LayoutBuilder |
getBuilder()
The reference to the LayoutBuilder that instanciated this Layout.
|
LayoutProperty[] |
getProperties()
The properties for this layout.
|
void |
goAlgo()
Run a step in the algorithm, should be called only if canAlgo() returns
true.
|
void |
initAlgo()
initAlgo() is called to initialize the algorithm (prepare to run).
|
void |
resetPropertiesValues()
Resets the properties values to the default values.
|
void |
setGraphModel(GraphModel graphModel)
Injects the graph model for the graph this Layout should operate on.
|
void initAlgo()
void setGraphModel(GraphModel graphModel)
It's preferable to get visible graph to perform on visualization.
graphModel
- the graph model that the layout is to be working onvoid goAlgo()
boolean canAlgo()
true
if the algorithm can run,
false
otherwisevoid endAlgo()
LayoutProperty[] getProperties()
NoSuchMethodException
void resetPropertiesValues()
LayoutBuilder getBuilder()
Copyright © 2007–2015 Gephi Consortium. All rights reserved.