code: public static List<Method> getMethodsListWithAnnotation(final Class<?> cls,
                                                              final Class<? extends Annotation> annotationCls,
                                                              final boolean searchSupers, final boolean ignoreAccess) {
  
          Validate.isTrue(cls != null, "The class must not be null");
          Validate.isTrue(annotationCls != null, "The annotation class must not be null");
          final List<Class<?>> classes = (searchSupers ? getAllSuperclassesAndInterfaces(cls)
                  : new ArrayList<Class<?>>());
          classes.add(0, cls);
          final List<Method> annotatedMethods = new ArrayList<>();
          for (final Class<?> acls : classes) {
              final Method[] methods = (ignoreAccess ? acls.getDeclaredMethods() : acls.getMethods());
              for (final Method method : methods) {
                  if (method.getAnnotation(annotationCls) != null) {
                      annotatedMethods.add(method);
                  }
              }
          }
          return annotatedMethods;
      }
docs: Gets all methods of the given class that are annotated with the given annotation.
  @param cls
  the {@link Class} to query
  @param annotationCls
  the {@link Annotation} that must be present on a method to be matched
  @param searchSupers
  determines if a lookup in the entire inheritance hierarchy of the given class should be performed
  @param ignoreAccess
  determines if non public methods should be considered
  @return a list of Methods (possibly empty).
  @throws IllegalArgumentException
  if the class or annotation are {@code null}
  @since 3.6