|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--drasys.or.graph.sp.Iterate
An implementation of an all pairs shortest path algorithm which iterates a single vertex shortest path algorithm.
References:
Introduction to Algorithms
Thomas H. Cormen, et al / Hardcover / Published 1990
Graphs : Theory and Algorithms
K. Thulasiraman, M.N.S. Swamy / Paperback / Published 1992
SingleVertexI
Constructor Summary | |
Iterate(GraphI graph)
A constructor that sets the target graph. |
|
Iterate(GraphI graph,
SingleVertexI algorithm)
A constructor that sets the target graph and the underlying single vertex shortest path algorithm. |
Method Summary | |
AddI |
fillGraph(AddI graph)
This finds all the paths costs from each of the origin vertices and all of the paths to each of the destination vertices. |
AddI |
fillGraph(AddI graph,
int maxPathsOut,
int maxPathsIn)
This finds the 'maxPathsOut' lowest cost paths from each of the origin vertices and the 'maxPathsIn' lowest cost paths to each of the destination vertices. |
void |
fillMatrix(SizableMatrixI cost,
SizableMatrixI time,
SizableMatrixI distance)
This finds the shortest path costs from all the origin vertices to all of the connected destination vertices. |
void |
fillMatrix(SizableMatrixI cost,
SizableMatrixI time,
SizableMatrixI distance,
int maxPathsOut,
int maxPathsIn)
This finds 'maxPathsOut' lowest costs from each of the origin vertices and the 'maxPathsIn' lowest costs into each of the destination vertices. |
VertexI[] |
getDestinationVertices()
Returns an array containing all of the destination vertices. |
VertexI[] |
getOriginVertices()
Returns an array containing all the origin vertices. |
void |
setDestination(boolean isDestination)
Sets the destination flags for all vertices equal to the argument. |
void |
setDestination(java.lang.Object key,
boolean isDestination)
Sets the destination flag for a vertex. |
void |
setOrigin(boolean isOrigin)
Sets the origin flags for all vertices equal to the argument. |
void |
setOrigin(java.lang.Object key,
boolean isOrigin)
Sets the origin flag for a vertex. |
void |
setProperties(PropertiesI properties)
Sets the properties object in the underlying single vertex algorithm. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public Iterate(GraphI graph)
public Iterate(GraphI graph, SingleVertexI algorithm)
Method Detail |
public void setProperties(PropertiesI properties)
public void setDestination(boolean isDestination)
public void setDestination(java.lang.Object key, boolean isDestination) throws VertexNotFoundException
public VertexI[] getDestinationVertices()
public void setOrigin(boolean isOrigin)
public void setOrigin(java.lang.Object key, boolean isOrigin) throws VertexNotFoundException
public VertexI[] getOriginVertices()
public void fillMatrix(SizableMatrixI cost, SizableMatrixI time, SizableMatrixI distance) throws InvalidPropertyException, VertexNotFoundException
public void fillMatrix(SizableMatrixI cost, SizableMatrixI time, SizableMatrixI distance, int maxPathsOut, int maxPathsIn) throws InvalidPropertyException, VertexNotFoundException
public AddI fillGraph(AddI graph) throws InvalidPropertyException, VertexNotFoundException, DuplicateEdgeException, DuplicateVertexException
public AddI fillGraph(AddI graph, int maxPathsOut, int maxPathsIn) throws InvalidPropertyException, VertexNotFoundException, DuplicateEdgeException, DuplicateVertexException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |