test/tools/javap/4870651/Test.java

changeset 46
7708bd6d800d
child 554
9d9f26857129
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/test/tools/javap/4870651/Test.java	Tue Jun 03 13:26:47 2008 -0700
     1.3 @@ -0,0 +1,76 @@
     1.4 +/*
     1.5 + * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
     1.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.7 + *
     1.8 + * This code is free software; you can redistribute it and/or modify it
     1.9 + * under the terms of the GNU General Public License version 2 only, as
    1.10 + * published by the Free Software Foundation.
    1.11 + *
    1.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
    1.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    1.14 + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    1.15 + * version 2 for more details (a copy is included in the LICENSE file that
    1.16 + * accompanied this code).
    1.17 + *
    1.18 + * You should have received a copy of the GNU General Public License version
    1.19 + * 2 along with this work; if not, write to the Free Software Foundation,
    1.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    1.21 + *
    1.22 + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
    1.23 + * CA 95054 USA or visit www.sun.com if you need additional information or
    1.24 + * have any questions.
    1.25 + */
    1.26 +
    1.27 +import java.util.*;
    1.28 +
    1.29 +abstract class Test<T,E extends Exception & Comparable<T>,U extends Comparable> {
    1.30 +    T t;
    1.31 +
    1.32 +    Test(T t) { }
    1.33 +    <G> Test(G g, int i) { }
    1.34 +
    1.35 +    Test(String... args) { }
    1.36 +    Test(int i, Object[]... args) { }
    1.37 +    abstract void v1(String... args);
    1.38 +    abstract void v2(int i, String[]... args);
    1.39 +
    1.40 +    abstract void a1(int x);
    1.41 +    abstract void a2(int[] x);
    1.42 +    abstract void a3(T x);
    1.43 +    abstract void a4(T[] x);
    1.44 +
    1.45 +    abstract int r1();
    1.46 +    abstract int[] r2();
    1.47 +    abstract T r3();
    1.48 +    abstract T[] r4();
    1.49 +
    1.50 +    abstract <G> void ga1(int x);
    1.51 +    abstract <G> void ga2(int[] x);
    1.52 +    abstract <G> void ga3(G x);
    1.53 +    abstract <G> void ga4(G[] x);
    1.54 +
    1.55 +    abstract <G> int gr1();
    1.56 +    abstract <G> int[] gr2();
    1.57 +    abstract <G> G gr3();
    1.58 +    abstract <G> G[] gr4();
    1.59 +
    1.60 +    abstract <G extends Exception> void ge() throws G;
    1.61 +
    1.62 +    abstract void w(List<?> l);
    1.63 +    abstract void we(List<? extends T> l);
    1.64 +    abstract void ws(List<? super T> l);
    1.65 +
    1.66 +    abstract void t1() throws Error;
    1.67 +    abstract void t2() throws E;
    1.68 +    abstract void t3() throws E,Error;
    1.69 +
    1.70 +    abstract void i1(Test<T, E, Comparable> x);
    1.71 +    abstract void i3(Test<T, E, Comparable>.Inner<String> x);
    1.72 +
    1.73 +    class Inner<Q> { }
    1.74 +    class Inner2<Q> extends Inner<Q> { }
    1.75 +
    1.76 +    class Simple { }
    1.77 +
    1.78 +    enum Enum { e1, e2, e3 }
    1.79 +}

mercurial