|
JGraphAddons |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jgraph.layout.JGraphLayoutAlgorithm
Field Summary | |
protected static Set |
LAYOUT_ATTRIBUTES
|
Constructor Summary | |
JGraphLayoutAlgorithm()
|
Method Summary | |
static void |
applyLayout(JGraph sourceGraph,
JGraphLayoutAlgorithm layout,
Object[] cells)
Calls applyLayout() with null static_cells |
static void |
applyLayout(JGraph sourceGraph,
JGraphLayoutAlgorithm layout,
Object[] dynamic_cells,
Object[] static_cells)
Takes a local clone of the JGraph and calls the run() method on the specified layout algorithm on the local JGraph. |
static JDialog |
createDialog(JGraphLayoutSettings settings,
JDialog parent,
String title,
String close,
String apply)
A utility method to create a simple dialog with close and apply button. |
static JDialog |
createDialog(JGraphLayoutSettings settings,
JFrame parent,
String title,
String close,
String apply)
A utility method to create a simple dialog with close and apply button. |
JGraphLayoutSettings |
createSettings()
Subclassers may return a new JComponent that allows to configure the layout. |
String |
getHint()
Get a human readable hint for using this layout. |
int |
getMaximumProgress()
Returns the maximum progress |
int |
getProgress()
Returns the current progress |
boolean |
isAllowedToRun()
|
static JDialog |
populateDialog(JGraphLayoutSettings settings,
JDialog dialog,
String close,
String apply)
A utility method to create a simple dialog with close and apply button. |
void |
run(JGraph graph,
Object[] cells)
Executes the layout algorithm with the given cells to be moved |
abstract void |
run(JGraph jgraph,
Object[] dynamic_cells,
Object[] static_cells)
Executes the layout algorithm specifying which cells are to remain in place after the layout is applied. |
void |
setAllowedToRun(boolean isAllowedToRun)
|
void |
setMaximumProgress(int maximumProgress)
Sets the maximum progress. |
void |
setProgress(int progress)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected static Set LAYOUT_ATTRIBUTES
Constructor Detail |
public JGraphLayoutAlgorithm()
Method Detail |
public JGraphLayoutSettings createSettings()
null
.
public String getHint()
public void run(JGraph graph, Object[] cells)
graph
- JGraph to be altered by layoutcells
- Array of cells to be moved by the layoutpublic abstract void run(JGraph jgraph, Object[] dynamic_cells, Object[] static_cells)
jgraph
- JGraph to be altered by layoutdynamic_cells
- Cells that are to be moved by the layoutstatic_cells
- Cells that are not to be moved, but allowed for by the layoutpublic boolean isAllowedToRun()
public void setAllowedToRun(boolean isAllowedToRun)
isAllowedToRun
- The isAllowedToRun to set.public int getMaximumProgress()
public void setMaximumProgress(int maximumProgress)
public int getProgress()
public void setProgress(int progress)
progress
- The progress complete amountpublic static JDialog createDialog(JGraphLayoutSettings settings, JFrame parent, String title, String close, String apply)
settings
- Layout settings instanceparent
- Parent JFrametitle
- Title of dialog boxclose
- Text for cancel buttonapply
- Text for apply button
public static JDialog createDialog(JGraphLayoutSettings settings, JDialog parent, String title, String close, String apply)
settings
- Layout settings instanceparent
- Parent JDialogtitle
- Title of dialog boxclose
- Text for cancel buttonapply
- Text for apply button
public static JDialog populateDialog(JGraphLayoutSettings settings, JDialog dialog, String close, String apply)
settings
- Layout settings instancedialog
- JDialog to be usedclose
- Text for cancel buttonapply
- Text for apply button
public static void applyLayout(JGraph sourceGraph, JGraphLayoutAlgorithm layout, Object[] cells)
sourceGraph
- The JGraph to have the layout appliedlayout
- The layout algorithm to be appliedcells
- Cells that are to be moved by the layoutpublic static void applyLayout(JGraph sourceGraph, JGraphLayoutAlgorithm layout, Object[] dynamic_cells, Object[] static_cells)
sourceGraph
- The JGraph to have the layout appliedlayout
- The layout algorithm to be applieddynamic_cells
- Cells that are to be moved by the layoutstatic_cells
- Cells that are not to be moved, but allowed for by the layout
|
JGraphAddons |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |