org.javanetworkanalyzer.alg
Class DFSForStrahler<E extends EdgeSPT>
java.lang.Object
org.javanetworkanalyzer.alg.GraphSearchAlgorithm<V,E>
org.javanetworkanalyzer.alg.DFS<VStrahler,E>
org.javanetworkanalyzer.alg.DFSForStrahler<E>
- All Implemented Interfaces:
- TraversalAlg<VStrahler,E>
public class DFSForStrahler<E extends EdgeSPT>
- extends DFS<VStrahler,E>
Calculates the Strahler numbers of the nodes in the given tree.
The graph passed to the constructor is assumed to be a tree. If is is not
a tree, this algorithm will return results, but they will be false.
This function is executed by calling
DFS.calculate(org.javanetworkanalyzer.data.VDFS) on the tree's root
node.
- Author:
- Adam Gouge
- See Also:
http://en.wikipedia.org/wiki/Strahler_number
|
Method Summary |
protected void |
visit(VStrahler node)
Visit the given node and calculate its Strahler number. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DFSForStrahler
public DFSForStrahler(org.jgrapht.Graph<VStrahler,E> graph)
- Constructor.
- Parameters:
graph - The graph.
visit
protected void visit(VStrahler node)
- Visit the given node and calculate its Strahler number.
- Overrides:
visit in class DFS<VStrahler,E extends EdgeSPT>
- Parameters:
node - The node.
Copyright © 2014. All Rights Reserved.