mwalk.visitor
Interface DownVisitor
- All Known Implementing Classes:
- DataVisitor, ExportVisitor, GlobalVisitor, LinkCountVisitor, MetricVisitor, VisualVisitor, MergeVisitor, DegreeCountVisitor, CollapseVisitor
- public interface DownVisitor
- extends Visitor
A standard interface used to interact with visitors that
walk the tree from the top down.
- Version:
- 1.0
- Author:
- Robert Chalmers
Method Summary |
TreeNode[] |
getChildren(Tree tree,
TreeNode node)
Get a list of children for the current node applying correct activity
semantics. |
java.lang.Object |
visitDown(Tree tree,
TreeNode node)
Visit the current node prior to visiting children. |
java.lang.Object |
visitDown(Tree tree,
TreeNode node,
java.util.Vector list)
Visit the current node after visiting children. |
boolean |
walkDown()
Whether to walk down the tree. |
walkDown
public boolean walkDown()
- Whether to walk down the tree.
- Returns:
boolean
whether to walk down the tree
visitDown
public java.lang.Object visitDown(Tree tree,
TreeNode node)
throws VisitException
- Visit the current node prior to visiting children.
This method is called if prefix() returns true.
- Parameters:
Tree
- current tree instanceTreeNode
- current node- Returns:
Object
optional return value to pass back along the path- Throws:
VisitException
- if a problem ocurred during visit
visitDown
public java.lang.Object visitDown(Tree tree,
TreeNode node,
java.util.Vector list)
throws VisitException
- Visit the current node after visiting children.
This method is called if postfix() returns true.
- Parameters:
Tree
- current tree instanceTreeNode
- current nodeVector
- list of return values passed back along the path- Returns:
Object
optional return value to pass back along the path- Throws:
VisitException
- if a problem ocurred during visit
getChildren
public TreeNode[] getChildren(Tree tree,
TreeNode node)
- Get a list of children for the current node applying correct activity
semantics.
- Parameters:
Tree
- current tree instanceTreeNode
- current node- Returns:
TreeNode[]
list of active children nodes
Submit a bug or feature mwalk Platform API Specification 0.3.0
Sensitivity: {Public:Research}
Copyright(c) 2000, Robert Chalmers