Gephi Toolkit Javadoc

org.gephi.layout.plugin
Class AbstractLayout

java.lang.Object
  extended by org.gephi.layout.plugin.AbstractLayout
All Implemented Interfaces:
Layout
Direct Known Subclasses:
ForceAtlasLayout, FruchtermanReingold, LabelAdjust, MultiLevelLayout, RandomLayout, RotateLayout, ScaleLayout, Test.TestLayout, YifanHuLayout

public abstract class AbstractLayout
extends java.lang.Object
implements Layout

Base class for layout algorithms.

Author:
Helder Suzuki

Field Summary
protected  DynamicModel dynamicModel
           
protected  GraphModel graphModel
           
 
Constructor Summary
AbstractLayout(LayoutBuilder layoutBuilder)
           
 
Method Summary
 boolean canAlgo()
          Tests if the algorithm can run, called before each pass.
 LayoutBuilder getBuilder()
          The reference to the LayoutBuilder that instanciated this Layout.
 boolean isConverged()
           
 void setConverged(boolean converged)
           
 void setGraphModel(GraphModel graphModel)
          Injects the graph model for the graph this Layout should operate on.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.gephi.layout.spi.Layout
endAlgo, getProperties, goAlgo, initAlgo, resetPropertiesValues
 

Field Detail

graphModel

protected GraphModel graphModel

dynamicModel

protected DynamicModel dynamicModel
Constructor Detail

AbstractLayout

public AbstractLayout(LayoutBuilder layoutBuilder)
Method Detail

getBuilder

public LayoutBuilder getBuilder()
Description copied from interface: Layout
The reference to the LayoutBuilder that instanciated this Layout.

Specified by:
getBuilder in interface Layout
Returns:
the reference to the builder that builts this instance

setGraphModel

public void setGraphModel(GraphModel graphModel)
Description copied from interface: Layout
Injects the graph model for the graph this Layout should operate on.

It's preferable to get visible graph to perform on visualization.

Specified by:
setGraphModel in interface Layout
Parameters:
graphModel - the graph model that the layout is to be working on

canAlgo

public boolean canAlgo()
Description copied from interface: Layout
Tests if the algorithm can run, called before each pass.

Specified by:
canAlgo in interface Layout
Returns:
true if the algorithm can run, false otherwise

setConverged

public void setConverged(boolean converged)

isConverged

public boolean isConverged()

Gephi Toolkit Javadoc