org.makumba.commons
Class GraphTS
java.lang.Object
org.makumba.commons.GraphTS
public class GraphTS
- extends Object
Graph which can do a topological sort of its elements. In our case, the elements are MultipleKeys of form tags.
- Version:
- $Id: GraphTS.java 5153 2010-05-18 21:37:50Z rosso_nero $
- Author:
- http://www.java2s.com/Code/Java/Collections-Data-Structure/Topologicalsorting.htm, Manuel Gay
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GraphTS
public GraphTS()
addVertex
public void addVertex(char lab)
addVertex
public int addVertex(MultipleKey tagKey)
addEdge
public void addEdge(int start,
int end)
displayVertex
public void displayVertex(int v)
getSortedKeys
public MultipleKey[] getSortedKeys()
topo
public void topo()
noSuccessors
public int noSuccessors()
deleteVertex
public void deleteVertex(int delVert)
main
public static void main(String[] args)