diff --git a/src/share/classes/java/lang/Class.java b/src/share/classes/java/lang/Class.java index 5593f2b4898ca5e9d1f1193af098d1d3537d00ce..c131a9c30711d7a0fd6dec6e7ccf13f47769da57 100644 --- a/src/share/classes/java/lang/Class.java +++ b/src/share/classes/java/lang/Class.java @@ -28,6 +28,7 @@ package java.lang; import java.lang.reflect.AnnotatedElement; import java.lang.reflect.Array; import java.lang.reflect.GenericArrayType; +import java.lang.reflect.GenericDeclaration; import java.lang.reflect.Member; import java.lang.reflect.Field; import java.lang.reflect.Executable; @@ -115,9 +116,9 @@ import sun.reflect.misc.ReflectUtil; * @since JDK1.0 */ public final class Class implements java.io.Serializable, - java.lang.reflect.GenericDeclaration, - java.lang.reflect.Type, - java.lang.reflect.AnnotatedElement { + GenericDeclaration, + Type, + AnnotatedElement { private static final int ANNOTATION= 0x00002000; private static final int ENUM = 0x00004000; private static final int SYNTHETIC = 0x00001000; @@ -3182,7 +3183,7 @@ public final class Class implements java.io.Serializable, */ @Override public boolean isAnnotationPresent(Class annotationClass) { - return AnnotatedElement.super.isAnnotationPresent(annotationClass); + return GenericDeclaration.super.isAnnotationPresent(annotationClass); } /** diff --git a/src/share/classes/java/lang/reflect/GenericDeclaration.java b/src/share/classes/java/lang/reflect/GenericDeclaration.java index 4f06c621f26ffff5010f3361c7b756151cfcefe0..042e359ad6f7dca430a7eb1eb1d780e336e02738 100644 --- a/src/share/classes/java/lang/reflect/GenericDeclaration.java +++ b/src/share/classes/java/lang/reflect/GenericDeclaration.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ package java.lang.reflect; * * @since 1.5 */ -public interface GenericDeclaration { +public interface GenericDeclaration extends AnnotatedElement { /** * Returns an array of {@code TypeVariable} objects that * represent the type variables declared by the generic