View Javadoc

1   /*
2    * $Id: IOASTNodeVisitor.java,v 1.5 2004/09/07 12:35:06 jlerner Exp $
3    *
4    * Copyright (c) 1999-2004, BBN Technologies, LLC.
5    * All rights reserved.
6    * http://www.daml.org/legal/opensource/bbn_license.html
7    */
8   package com.bbn.swede.core.dom;
9   
10  /***
11   * Interface for performing preorder traversals against an OAST subtree.
12   * @see OASTNode#accept(IOASTNodeVisitor)
13   * @author jlerner
14   */
15  public interface IOASTNodeVisitor
16  {
17     /***
18      * Performs the recursion's action for a node.  The return value indicates 
19      * whether to process the node's children. 
20      * @param node The node
21      * @return <code>true</code> to continue and visit <code>node</code>'s 
22      *         children, <code>false</code> to prevent them from being processed.
23      */
24     boolean visit(OASTNode node);
25  }