1.1 --- a/emul/src/main/java/java/lang/Class.java Tue Dec 04 12:16:16 2012 +0100
1.2 +++ b/emul/src/main/java/java/lang/Class.java Tue Dec 04 14:31:11 2012 +0100
1.3 @@ -27,6 +27,7 @@
1.4
1.5 import java.io.InputStream;
1.6 import java.lang.annotation.Annotation;
1.7 +import java.lang.reflect.TypeVariable;
1.8 import org.apidesign.bck2brwsr.core.JavaScriptBody;
1.9
1.10 /**
1.11 @@ -75,10 +76,10 @@
1.12 * @since JDK1.0
1.13 */
1.14 public final
1.15 - class Class<T> implements java.io.Serializable {
1.16 -// java.lang.reflect.GenericDeclaration,
1.17 -// java.lang.reflect.Type,
1.18 -// java.lang.reflect.AnnotatedElement {
1.19 + class Class<T> implements java.io.Serializable,
1.20 + java.lang.reflect.GenericDeclaration,
1.21 + java.lang.reflect.Type,
1.22 + java.lang.reflect.AnnotatedElement {
1.23 private static final int ANNOTATION= 0x00002000;
1.24 private static final int ENUM = 0x00004000;
1.25 private static final int SYNTHETIC = 0x00001000;
1.26 @@ -396,6 +397,26 @@
1.27 @JavaScriptBody(args = "self", body = "return self.jvmName;")
1.28 private native String jvmName();
1.29
1.30 +
1.31 + /**
1.32 + * Returns an array of {@code TypeVariable} objects that represent the
1.33 + * type variables declared by the generic declaration represented by this
1.34 + * {@code GenericDeclaration} object, in declaration order. Returns an
1.35 + * array of length 0 if the underlying generic declaration declares no type
1.36 + * variables.
1.37 + *
1.38 + * @return an array of {@code TypeVariable} objects that represent
1.39 + * the type variables declared by this generic declaration
1.40 + * @throws java.lang.reflect.GenericSignatureFormatError if the generic
1.41 + * signature of this generic declaration does not conform to
1.42 + * the format specified in
1.43 + * <cite>The Java™ Virtual Machine Specification</cite>
1.44 + * @since 1.5
1.45 + */
1.46 + public TypeVariable<Class<T>>[] getTypeParameters() {
1.47 + throw new UnsupportedOperationException();
1.48 + }
1.49 +
1.50 /**
1.51 * Returns the {@code Class} representing the superclass of the entity
1.52 * (class, interface, primitive type or void) represented by this