langtools/test/tools/doclint/ValidTest.java
author katleman
Tue, 21 Jan 2014 18:17:23 -0800
changeset 22365 895bfde469d4
parent 14962 19ffdfafbcd2
child 25452 581d57f5c7d8
permissions -rw-r--r--
Added tag jdk9-b01 for changeset ae2d94255f32
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
14952
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     1
/*
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     2
 * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     4
 *
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     7
 * published by the Free Software Foundation.
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     8
 *
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    13
 * accompanied this code).
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    14
 *
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    18
 *
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    21
 * questions.
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    22
 */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    23
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    24
/*
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    25
 * @test
14962
19ffdfafbcd2 8005307: fix missing @bug tags
jjg
parents: 14952
diff changeset
    26
 * @bug 8004832
19ffdfafbcd2 8005307: fix missing @bug tags
jjg
parents: 14952
diff changeset
    27
 * @summary Add new doclint package
14952
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    28
 * @build DocLintTester
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    29
 * @run main DocLintTester ValidTest.java
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    30
 */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    31
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    32
class ValidTest {
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    33
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    34
     * < > & (
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    35
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    36
    void entities() { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    37
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    38
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    39
     * <h1> ... </h1>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    40
     * <h2> ... </h2>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    41
     * <h3> ... </h3>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    42
     * <h4> ... </h4>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    43
     * <h5> ... </h5>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    44
     * <h6> ... </h6>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    45
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    46
    void all_headers() { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    47
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    48
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    49
     * <h1> ... </h1>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    50
     * <h2> ... </h2>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    51
     * <h3> ... </h3>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    52
     * <h1> ... </h1>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    53
     * <h2> ... </h2>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    54
     * <h3> ... </h3>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    55
     * <h2> ... </h2>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    56
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    57
    void header_series() { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    58
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    59
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    60
     * <div> <p>   </div>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    61
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    62
    void autoclose_tags() { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    63
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    64
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    65
     * @param x
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    66
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    67
    void method_param(int x) { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    68
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    69
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    70
     * @param <T>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    71
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    72
    <T> T method_typaram(T t) { return t; }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    73
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    74
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    75
     * @param <T>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    76
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    77
    class ClassTyparam<T> { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    78
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    79
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    80
     * @param <T>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    81
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    82
    interface InterfaceTyparam<T> { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    83
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    84
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    85
     * @return x
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    86
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    87
    int return_int() { return 0; }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    88
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    89
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    90
     * @exception Exception
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    91
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    92
    void throws_Exception1() throws Exception { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    93
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    94
    /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    95
     * @throws Exception
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    96
     */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    97
    void throws_Exception2() throws Exception { }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    98
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
    99
    class X {
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   100
        /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   101
         * @param x
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   102
         */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   103
        X(int x) { } // constructor parameter
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   104
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   105
        /**
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   106
         * @param <T>
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   107
         */
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   108
        <T> X(T t) { } // constructor type parameter
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   109
    }
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   110
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   111
}
d0022ae20516 8004832: Add new doclint package
jjg
parents:
diff changeset
   112