|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public static interface NodeTraversal.Callback
Callback
Method Summary | |
---|---|
boolean |
shouldTraverse(NodeTraversal nodeTraversal,
Node n,
Node parent)
Visits a node in pre order (before visiting its children) and decides whether this node's children should be traversed. |
void |
visit(NodeTraversal t,
Node n,
Node parent)
Visits a node in post order (after its children have been visited). |
Method Detail |
---|
boolean shouldTraverse(NodeTraversal nodeTraversal, Node n, Node parent)
Visits a node in pre order (before visiting its children) and decides
whether this node's children should be traversed. If children are
traversed, they will be visited by
visit(NodeTraversal, Node, Node)
in post order.
Implementations can have side effects (e.g. modifying the parse tree).
void visit(NodeTraversal t, Node n, Node parent)
Visits a node in post order (after its children have been visited).
A node is visited only if all its parents should be traversed
(shouldTraverse(NodeTraversal, Node, Node)
).
Implementations can have side effects (e.g. modifying the parse tree).
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |