Logo Search packages:      
Sourcecode: antlr version File versions

ASTEnumeration antlr::BaseAST::findAll ( AST  target  )  [inline, inherited]

Walk the tree looking for all exact subtree matches. Return an ASTEnumerator that lets the caller walk the list of subtree roots found herein.

Implements antlr::collections::AST.

Definition at line 214 of file BaseAST.java.

        Vector roots = new Vector(10);
        AST sibling;

        // the empty tree cannot result in an enumeration
        if (target == null) {
            return null;

        doWorkForFindAll(roots, target, false);  // find all matches recursively

        return new ASTEnumerator(roots);

Generated by  Doxygen 1.6.0   Back to index