code: public static Method getMethod(Class<?> clazz, final Class<? extends Annotation> annotation) {
          return traverseHierarchy(clazz, new TraverseTask<Method>() {
  
              @Override
              public Method run(Class<?> clazz) {
                  Method[] methods = clazz.getDeclaredMethods();
  
                  for (int i = 0; i < methods.length; i++) {
                      Method m = methods[i];
                      if (m.getAnnotation(annotation) != null) {
                          return m;
                      }
                  }
  
                  return null;
              }
          });
      }
docs: Returns the method object for a method which is annotated with the
  given annotation of the given class. This method traverses through
  the super classes of the given class and tries to find the method as
  declared method within these classes that is annotated with an
  annotation of the given annotation type.
  When the object class is reached the traversing stops. If the method can
  not be found, null is returned.
  This methods immediatelly returns the first method found that is
  annotated with an annotation of the given type.
  To retrieve all methods annotated with the given annotation type see
  {@link ReflectionUtils#getMethods(java.lang.Class, java.lang.Class)}
  
  @param clazz      The class within to look for the method
  @param annotation The annotation type a method must be annotated with to be
  returned
  @return The method object for the method annotated with the given
  annotation type if the method can be found, otherwise null