ca.quine.jcommons.transform.graph
Class MarkAllUnnecessaryEdges
java.lang.Object
|
+--ca.quine.jcommons.transform.graph.MarkAllUnnecessaryEdges
- All Implemented Interfaces:
- IDFSNodeApplicator
- public class MarkAllUnnecessaryEdges
- extends Object
- implements IDFSNodeApplicator
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MarkAllUnnecessaryEdges
public MarkAllUnnecessaryEdges()
applyPreOrder
public int applyPreOrder(TransformNode parentNode,
TransformNode node)
- Description copied from interface:
IDFSNodeApplicator
- Apply the parent node and child node of every edge in pre-order DFS
order.
- Specified by:
applyPreOrder
in interface IDFSNodeApplicator
- Parameters:
parentNode
- node
-
- Returns:
IDFSNodeApplicator.SEARCH_CONTINUE
, IDFSNodeApplicator.SEARCH_STOP
, or
IDFSNodeApplicator.SEARCH_TRIM
applyPostOrder
public int applyPostOrder(TransformNode parentNode,
TransformNode node)
- Description copied from interface:
IDFSNodeApplicator
- Apply the parent node and child node of every edge in post-order DFS
order;
IDFSNodeApplicator.SEARCH_TRIM
is not a valid return for this method.
- Specified by:
applyPostOrder
in interface IDFSNodeApplicator
- Parameters:
parentNode
- node
-
- Returns:
IDFSNodeApplicator.SEARCH_CONTINUE
, IDFSNodeApplicator.SEARCH_STOP
applyForwardEdge
public int applyForwardEdge(TransformNode parentNode,
TransformNode node)
- Description copied from interface:
IDFSNodeApplicator
- Apply the parent node and child node of every "forward edge" in DFS
order;
IDFSNodeApplicator.SEARCH_TRIM
is not a valid return for this method.
For more information on forward edges, please consult
"Introduction to Algorithms", Cormen, Leiserson, and Rivest, 1990.
- Specified by:
applyForwardEdge
in interface IDFSNodeApplicator
- Parameters:
parentNode
- node
-
- Returns:
IDFSNodeApplicator.SEARCH_CONTINUE
, IDFSNodeApplicator.SEARCH_STOP