N
- The node type for the graphE
- The edge type for the graphpublic class TargetArrangement<N,E> extends FocusArrangement<N> implements TreeArrangement<N>, GraphArrangement<N,E>
Arrangement class which will arrange all nodes in a radial pattern with the designated target node in the center. All other nodes are arranged in radial tiers from the target, by their level of connectedness.
Any nodes which are not connected to the target node are not arranged. This is to allow the arrangement to handle a number of different clusters within the same graph.
Constructor and Description |
---|
TargetArrangement() |
Modifier and Type | Method and Description |
---|---|
void |
arrange(Graph<N,E> graph)
Arranges the specified Graph.
|
void |
arrange(Tree<N> tree)
Arrange the specified tree.
|
java.awt.Point |
getCenter()
Get the center that the arrangement is using.
|
int |
getRadiusStep()
Get the radius step, which is the distance between successive tiers of
the arrangement
|
void |
setCenter(java.awt.Point centerPoint)
Set the center point for the arrangement.
|
void |
setRadiusStep(int step)
Set the radius step for the arrangement.
|
focusOnMostConnected, getFocusNode, setFocusNode
getMargin, getNodeLocation, getSize, invalidate, setMargin, setNodeLocation, setSize, setSize
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getNodeLocation, getSize, setMargin, setSize, setSize
public void arrange(Graph<N,E> graph) throws ArrangementException
arrange
in interface GraphArrangement<N,E>
graph
- the graph to be arrangedArrangementException
- If there is a problem determining the
arrangementpublic void arrange(Tree<N> tree)
arrange
in interface TreeArrangement<N>
tree
- the tree to arrangepublic java.awt.Point getCenter()
public int getRadiusStep()
public void setCenter(java.awt.Point centerPoint)
centerPoint
- the center pointpublic void setRadiusStep(int step)
step
- the radius step