< prev index next >

src/java.base/share/classes/java/lang/Class.java

Print this page

        

@@ -915,11 +915,11 @@
      * the entity (class, interface, primitive type or void) represented by
      * this {@code Class}.
      *
      * <p>If the superclass is a parameterized type, the {@code Type}
      * object returned must accurately reflect the actual type
-     * parameters used in the source code. The parameterized type
+     * arguments used in the source code. The parameterized type
      * representing the superclass is created if it had not been
      * created before. See the declaration of {@link
      * java.lang.reflect.ParameterizedType ParameterizedType} for the
      * semantics of the creation process for parameterized types.  If
      * this {@code Class} represents either the {@code Object}

@@ -1095,11 +1095,11 @@
      * directly implemented by the class or interface represented by
      * this object.
      *
      * <p>If a superinterface is a parameterized type, the
      * {@code Type} object returned for it must accurately reflect
-     * the actual type parameters used in the source code. The
+     * the actual type arguments used in the source code. The
      * parameterized type representing each superinterface is created
      * if it had not been created before. See the declaration of
      * {@link java.lang.reflect.ParameterizedType ParameterizedType}
      * for the semantics of the creation process for parameterized
      * types.

@@ -3638,13 +3638,16 @@
         else
             throw new ClassCastException(this.toString());
     }
 
     /**
+     * {@inheritDoc}
+     * <p>Any annotation returned by this method is a declaration annotation.
      * @throws NullPointerException {@inheritDoc}
      * @since 1.5
      */
+    @Override
     @SuppressWarnings("unchecked")
     public <A extends Annotation> A getAnnotation(Class<A> annotationClass) {
         Objects.requireNonNull(annotationClass);
 
         return (A) annotationData().annotations.get(annotationClass);

@@ -3659,10 +3662,12 @@
     public boolean isAnnotationPresent(Class<? extends Annotation> annotationClass) {
         return GenericDeclaration.super.isAnnotationPresent(annotationClass);
     }
 
     /**
+     * {@inheritDoc}
+     * <p>Any annotations returned by this method are declaration annotations.
      * @throws NullPointerException {@inheritDoc}
      * @since 1.8
      */
     @Override
     public <A extends Annotation> A[] getAnnotationsByType(Class<A> annotationClass) {

@@ -3673,17 +3678,22 @@
                                                           this,
                                                           annotationClass);
     }
 
     /**
+     * {@inheritDoc}
+     * <p>Any annotations returned by this method are declaration annotations.
      * @since 1.5
      */
+    @Override
     public Annotation[] getAnnotations() {
         return AnnotationParser.toArray(annotationData().annotations);
     }
 
     /**
+     * {@inheritDoc}
+     * <p>Any annotation returned by this method is a declaration annotation.
      * @throws NullPointerException {@inheritDoc}
      * @since 1.8
      */
     @Override
     @SuppressWarnings("unchecked")

@@ -3692,10 +3702,12 @@
 
         return (A) annotationData().declaredAnnotations.get(annotationClass);
     }
 
     /**
+     * {@inheritDoc}
+     * <p>Any annotations returned by this method are declaration annotations.
      * @throws NullPointerException {@inheritDoc}
      * @since 1.8
      */
     @Override
     public <A extends Annotation> A[] getDeclaredAnnotationsByType(Class<A> annotationClass) {

@@ -3704,12 +3716,15 @@
         return AnnotationSupport.getDirectlyAndIndirectlyPresent(annotationData().declaredAnnotations,
                                                                  annotationClass);
     }
 
     /**
+     * {@inheritDoc}
+     * <p>Any annotations returned by this method are declaration annotations.
      * @since 1.5
      */
+    @Override
     public Annotation[] getDeclaredAnnotations()  {
         return AnnotationParser.toArray(annotationData().declaredAnnotations);
     }
 
     // annotation data that might get invalidated when JVM TI RedefineClasses() is called
< prev index next >