[jgrapht-users] How to stop traversing at a given node
Brought to you by:
barak_naveh,
perfecthash
From: Robert L. <rob...@gm...> - 2010-07-06 20:05:59
|
Can someone please tell me how to traverse a graph breadth first (depth first OK too) and to stop going down the current branch based on information that's stored in the just-visited node. Using *<http://www.jgrapht.org/javadoc/org/jgrapht/traverse/BreadthFirstIterator.html> *BreadthFirstIterator<V,E> seems to be the way to go but I can't figure out how to tell the traverser to stop going down the path once I've visited a node and recognized it as a stopping point. Any thoughts? |