|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
The interface Graph is used to describe a the structure of a bi-dimensional graph.
It is used directly by the positioning algorithms.
The needed methods are described below.
A Graph must provide the dimension of the available area used to locate the vertices.
It must provide the number of vertices, their positions and their maximum dimensions i.e. the width and
the height of their bounding box (the rectangle in which a vertex is contained).
The Graph must provide also a method used to evaluate the positions given by the algorithm
without modifying the initial positions.
The positions are modified only with the method setPositions(double[][]).
| Method Summary | |
double |
evaluatePositions(double[][] positions)
Evaluate the given positions to the vertices of the graph. |
double |
getAvailableHeight()
Return the height of the area the graph must be contained in. |
double |
getAvailableWidth()
Return the width of the area the graph must be contained in. |
int[][] |
getEdgeIndices()
Return the indices of the two vertices of each edge in the graph. |
int |
getEdgeNumber()
This method return the number of edges in the graph. |
double[][] |
getMaximumDimensions()
Return an array containing the maximum width and the maximum height of each vertex. |
double[][] |
getPositions()
Return the positions of the vertices in the graph. |
int |
getSize()
This method return the number of vertices in the graph. |
void |
setPositions(double[][] positions)
Set the given positions to the vertices of the graph. |
| Method Detail |
public int getSize()
public int getEdgeNumber()
SymmetricPositioning algorithm.
public double getAvailableWidth()
public double getAvailableHeight()
public double[][] getPositions()
public void setPositions(double[][] positions)
positions - the new positons of the vertices.public double evaluatePositions(double[][] positions)
GeneticPositioning algorithm.
positions - the positions to evaluate.
public double[][] getMaximumDimensions()
public int[][] getEdgeIndices()
SymmetricPositioning algorithm.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||