Interface AnnotationFinder


public interface AnnotationFinder
  • Field Summary

    Fields
    Modifier and Type Field Description
    static AnnotationFinder DEFAULT  
  • Method Summary

    Modifier and Type Method Description
    default <A extends java.lang.annotation.Annotation>
    A
    findAnnotation​(java.lang.reflect.AnnotatedElement annotatedElement, java.lang.Class<A> annotationType)
    The default implementation performs a simple search for a declared annotation matching the search type.
  • Field Details

  • Method Details

    • findAnnotation

      default <A extends java.lang.annotation.Annotation> A findAnnotation​(java.lang.reflect.AnnotatedElement annotatedElement, java.lang.Class<A> annotationType)
      The default implementation performs a simple search for a declared annotation matching the search type. Spring provides a more sophisticated annotation search utility that matches on meta-annotations as well.
      Type Parameters:
      A - Annotation type to search for.
      Parameters:
      annotatedElement - The element to search.
      annotationType - The annotation type class.
      Returns:
      A matching annotation.