code: public static Method findMethod(String name, Class<?> cls) {
      
      for(Method method : cls.getDeclaredMethods()) {
        if(method.getName().equals(name)) {
          return method;
        }
      }
      
      throw new ExecutionException("invalid auto-function: no '" + name + "' method declared", null);
    }
docs: Finds a named declared method on the given class.
  
  @param name Name of declared method to retrieve
  @param cls Class to retrieve method from
  @return Named method on class