code: public static Method getDeclaredMethod(Class<?> clazz, String name, Class<?>... params) {
          try {
              return clazz.getDeclaredMethod(name, params);
          } catch (Exception e) {
              throw new IllegalArgumentException("Could not access method: " + name + " on " + clazz, e);
          }
      }
docs: Returns the named method from class <i>clazz</i>, does not throw checked exceptions.
  
  @param clazz
  The class to inspect
  @param name
  The name of the method to get
  @param params
  Parameter types for the method
  
  
  @return Returns the named method from class <i>clazz</i>.
  
  @throws IllegalArgumentException if method could not be found or security
  issues occurred, when trying to retrieve the method.