code: public static boolean hasAnnotation(Method method, Class<? extends Annotation> annotation) {
          return !searchForAnnotation(method, annotation).isEmpty();
      }
docs: Checks if there is an annotation of the given type on this method or on type level for all interfaces and superclasses
  
  @param method     the method to scan
  @param annotation the annotation to search for
  @return <i>true</i> if the given annotation is present on method or type level annotations in the type hierarchy