689 * @since 1.5 690 */ 691 public <T extends Annotation> T getAnnotation(Class<T> annotationClass) { 692 return super.getAnnotation(annotationClass); 693 } 694 695 /** 696 * {@inheritDoc} 697 * @since 1.5 698 */ 699 public Annotation[] getDeclaredAnnotations() { 700 return super.getDeclaredAnnotations(); 701 } 702 703 /** 704 * {@inheritDoc} 705 * @since 1.5 706 */ 707 @Override 708 public Annotation[][] getParameterAnnotations() { 709 return sharedGetParameterAnnotations(parameterTypes, parameterAnnotations); 710 } 711 712 /** 713 * {@inheritDoc} 714 * @since 1.8 715 */ 716 @Override 717 public AnnotatedType getAnnotatedReturnType() { 718 return getAnnotatedReturnType0(getGenericReturnType()); 719 } 720 721 @Override 722 void handleParameterNumberMismatch(int resultLength, int numParameters) { 723 throw new AnnotationFormatError("Parameter annotations don't match number of parameters"); 724 } 725 } | 689 * @since 1.5 690 */ 691 public <T extends Annotation> T getAnnotation(Class<T> annotationClass) { 692 return super.getAnnotation(annotationClass); 693 } 694 695 /** 696 * {@inheritDoc} 697 * @since 1.5 698 */ 699 public Annotation[] getDeclaredAnnotations() { 700 return super.getDeclaredAnnotations(); 701 } 702 703 /** 704 * {@inheritDoc} 705 * @since 1.5 706 */ 707 @Override 708 public Annotation[][] getParameterAnnotations() { 709 if (parameterAnnotations == null) { 710 return new Annotation[parameterTypes.length][0]; 711 } else { 712 Annotation[][] anns = parseParameterAnnotations(parameterAnnotations); 713 if (anns.length != parameterTypes.length) { 714 throwParameterAnnotationsDontMatchNumberOfParameters(); 715 } 716 return anns; 717 } 718 } 719 720 /** 721 * {@inheritDoc} 722 * @since 1.8 723 */ 724 @Override 725 public AnnotatedType getAnnotatedReturnType() { 726 return getAnnotatedReturnType0(getGenericReturnType()); 727 } 728 } |