< prev index next >

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

Print this page

        

*** 432,444 **** --- 432,449 ---- } return packageInfo; } /** + * {@inheritDoc} + * <p>Note that any annotation returned by this method is a + * declaration annotation. + * * @throws NullPointerException {@inheritDoc} * @since 1.5 */ + @Override public <A extends Annotation> A getAnnotation(Class<A> annotationClass) { return getPackageInfo().getAnnotation(annotationClass); } /**
*** 450,475 **** --- 455,492 ---- public boolean isAnnotationPresent(Class<? extends Annotation> annotationClass) { return AnnotatedElement.super.isAnnotationPresent(annotationClass); } /** + * {@inheritDoc} + * <p>Note that 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) { return getPackageInfo().getAnnotationsByType(annotationClass); } /** + * {@inheritDoc} + * <p>Note that any annotations returned by this method are + * declaration annotations. * @since 1.5 */ + @Override public Annotation[] getAnnotations() { return getPackageInfo().getAnnotations(); } /** + * {@inheritDoc} + * <p>Note that any annotation returned by this method is a + * declaration annotation. + * * @throws NullPointerException {@inheritDoc} * @since 1.8 */ @Override public <A extends Annotation> A getDeclaredAnnotation(Class<A> annotationClass) {
*** 484,495 **** --- 501,516 ---- public <A extends Annotation> A[] getDeclaredAnnotationsByType(Class<A> annotationClass) { return getPackageInfo().getDeclaredAnnotationsByType(annotationClass); } /** + * {@inheritDoc} + * <p>Note that any annotations returned by this method are + * declaration annotations. * @since 1.5 */ + @Override public Annotation[] getDeclaredAnnotations() { return getPackageInfo().getDeclaredAnnotations(); } /**
< prev index next >