langtools/test/tools/javac/doctree/DocTreePathScannerTest.java
author sogoel
Thu, 05 Jun 2014 10:57:10 -0700
changeset 24797 850ebd4d80a7
parent 17549 65ea6f3b72d9
child 27319 030080f03e4f
permissions -rw-r--r--
8044072: Group 2: create .out files for OverrideChecks tests in tools/javac dir Reviewed-by: jjg
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
17549
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     1
/*
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     2
 * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     4
 *
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     7
 * published by the Free Software Foundation.
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     8
 *
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    13
 * accompanied this code).
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    14
 *
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    18
 *
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    21
 * questions.
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    22
 */
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    23
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    24
/*
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    25
 * @test
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    26
 * @bug 8009724
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    27
 * @summary adding DocTreePath and DocTreePathScanner
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    28
 */
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    29
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    30
import com.sun.source.doctree.DocCommentTree;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    31
import com.sun.source.doctree.DocTree;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    32
import com.sun.source.doctree.DocTree.Kind;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    33
import com.sun.source.doctree.DocTreeVisitor;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    34
import com.sun.source.tree.ClassTree;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    35
import com.sun.source.tree.CompilationUnitTree;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    36
import com.sun.source.tree.MethodTree;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    37
import com.sun.source.tree.Tree;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    38
import com.sun.source.tree.VariableTree;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    39
import com.sun.source.util.DocTreePath;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    40
import com.sun.source.util.DocTreePathScanner;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    41
import com.sun.source.util.DocTreeScanner;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    42
import com.sun.source.util.DocTrees;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    43
import com.sun.source.util.JavacTask;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    44
import com.sun.source.util.TreePath;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    45
import com.sun.source.util.TreePathScanner;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    46
import com.sun.tools.javac.api.JavacTool;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    47
import java.io.File;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    48
import java.util.ArrayList;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    49
import java.util.List;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    50
import javax.lang.model.element.Name;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    51
import javax.tools.JavaFileObject;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    52
import javax.tools.StandardJavaFileManager;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    53
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    54
public class DocTreePathScannerTest {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    55
    public static void main(String... args) throws Exception {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    56
        DocTreePathScannerTest t = new DocTreePathScannerTest();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    57
        t.run();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    58
    }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    59
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    60
    void run() throws Exception {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    61
        List<File> files = new ArrayList<File>();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    62
        File testSrc = new File(System.getProperty("test.src"));
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    63
        for (File f: testSrc.listFiles()) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    64
            if (f.isFile() && f.getName().endsWith(".java"))
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    65
                files.add(f);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    66
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    67
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    68
        JavacTool javac = JavacTool.create();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    69
        StandardJavaFileManager fm = javac.getStandardFileManager(null, null, null);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    70
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    71
        Iterable<? extends JavaFileObject> fos = fm.getJavaFileObjectsFromFiles(files);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    72
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    73
        JavacTask t = javac.getTask(null, fm, null, null, null, fos);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    74
        DocTrees trees = DocTrees.instance(t);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    75
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    76
        Iterable<? extends CompilationUnitTree> units = t.parse();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    77
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    78
        DeclScanner ds = new DeclScanner(trees);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    79
        for (CompilationUnitTree unit: units) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    80
            ds.scan(unit, null);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    81
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    82
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    83
        if (errors > 0)
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    84
            throw new Exception(errors + " errors occurred");
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    85
    }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    86
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    87
    void error(String msg) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    88
        System.err.println("Error: " + msg);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    89
        errors++;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    90
    }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    91
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    92
    int errors;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    93
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    94
    class DeclScanner extends TreePathScanner<Void, Void> {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    95
        DocTrees trees;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    96
        DocTreePathScanner<Void,Void> cs;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    97
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    98
        DeclScanner(DocTrees trees) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
    99
            this.trees = trees;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   100
            cs = new CommentPathScanner();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   101
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   102
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   103
        @Override
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   104
        public Void visitClass(ClassTree tree, Void ignore) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   105
            super.visitClass(tree, ignore);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   106
            visitDecl(tree, tree.getSimpleName());
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   107
            return null;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   108
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   109
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   110
        @Override
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   111
        public Void visitMethod(MethodTree tree, Void ignore) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   112
            super.visitMethod(tree, ignore);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   113
            visitDecl(tree, tree.getName());
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   114
            return null;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   115
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   116
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   117
        @Override
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   118
        public Void visitVariable(VariableTree tree, Void ignore) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   119
            super.visitVariable(tree, ignore);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   120
            visitDecl(tree, tree.getName());
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   121
            return null;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   122
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   123
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   124
        void visitDecl(Tree tree, Name name) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   125
            TreePath path = getCurrentPath();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   126
            DocCommentTree dc = trees.getDocCommentTree(path);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   127
            if (dc != null)
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   128
                cs.scan(new DocTreePath(path, dc), null);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   129
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   130
    }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   131
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   132
    class CommentPathScanner extends DocTreePathScanner<Void, Void> {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   133
        CommentPathScanner() {}
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   134
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   135
        @Override
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   136
        public Void scan(final DocTree tree, Void ignore) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   137
            if (tree != null) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   138
                DocTree previous = null;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   139
                for (DocTree current : getCurrentPath()) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   140
                    if (previous != null) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   141
                        final List<DocTree> children = new ArrayList<>();
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   142
                        current.accept(new DocTreeScanner<Void, Void>() {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   143
                            @Override public Void scan(DocTree node, Void p) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   144
                                children.add(node);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   145
                                return null;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   146
                            }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   147
                        }, null);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   148
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   149
                        if (!children.contains(previous)) {
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   150
                            error("Invalid DocTreePath for: " + tree);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   151
                        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   152
                    }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   153
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   154
                    previous = current;
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   155
                }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   156
            }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   157
            return super.scan(tree, ignore);
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   158
        }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   159
    }
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   160
65ea6f3b72d9 8009724: Enhance the DocTree API with DocTreePath
jlahoda
parents:
diff changeset
   161
}