org.wilmascope.highdimensionlayout
Class HighDimensionLayout

java.lang.Object
  extended by org.wilmascope.graph.LayoutEngine
      extended by org.wilmascope.highdimensionlayout.HighDimensionLayout

public class HighDimensionLayout
extends LayoutEngine

Author:
cmurray

Field Summary
static int k
           
static int m
           
 
Constructor Summary
HighDimensionLayout()
           
 
Method Summary
 boolean applyLayout()
          apply the changes calculated by LayoutEngine.calculateLayout()
 void calculateLayout()
          calculate the changes required to move the graph to a nicer layout.
 EdgeLayout createEdgeLayout(Edge e)
          Factory method to create a new EdgeLayout implementation compatible with the layout engine implementing this interface.
 NodeLayout createNodeLayout(Node n)
          Factory method to create a new NodeLayout implementation compatible with the layout engine implementing this interface.
 javax.swing.JPanel getControls()
           
 java.lang.String getName()
          Return a string descriptor for the layout engine type.
 
Methods inherited from class org.wilmascope.graph.LayoutEngine
getProperties, getRoot, init, isIterative, resetProperties, setProperties
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m

public static final int m
See Also:
Constant Field Values

k

public static final int k
See Also:
Constant Field Values
Constructor Detail

HighDimensionLayout

public HighDimensionLayout()
Method Detail

calculateLayout

public void calculateLayout()
Description copied from class: LayoutEngine
calculate the changes required to move the graph to a nicer layout. This method does not actually update the position of the nodes, rather this should be done by the LayoutEngine.applyLayout() method. Potentially, this means that the caller can calculate new positions (stored in the NodeLayouts), then opt not to apply the changes if it does not lead to an improvement. In practice this has not yet been utilised and such decisions are usually made internally to the layout engine.

Overrides:
calculateLayout in class LayoutEngine

applyLayout

public boolean applyLayout()
Description copied from class: LayoutEngine
apply the changes calculated by LayoutEngine.calculateLayout()

Specified by:
applyLayout in class LayoutEngine
Returns:
true when a stable state is reached

getName

public java.lang.String getName()
Description copied from class: LayoutEngine
Return a string descriptor for the layout engine type. Useful in GUI elements such as comboboxes

Specified by:
getName in class LayoutEngine

createNodeLayout

public NodeLayout createNodeLayout(Node n)
Description copied from class: LayoutEngine
Factory method to create a new NodeLayout implementation compatible with the layout engine implementing this interface.

Specified by:
createNodeLayout in class LayoutEngine

createEdgeLayout

public EdgeLayout createEdgeLayout(Edge e)
Description copied from class: LayoutEngine
Factory method to create a new EdgeLayout implementation compatible with the layout engine implementing this interface.

Specified by:
createEdgeLayout in class LayoutEngine

getControls

public javax.swing.JPanel getControls()
Specified by:
getControls in class LayoutEngine