code: private static Method lookupMethod(Class type, String name, Class... args) {
          try {
              return type.getMethod(name, args);
          } catch (NoSuchMethodException e) {
              Error error = new NoSuchMethodError();
              error.initCause(e);
              throw error;
          }
      }
docs: /*
  private static Method lookupMethod(Class type, MethodInfo mi) {
  MethodDesc desc = mi.getMethodDescriptor();
  TypeDesc[] params = desc.getParameterTypes();
  Class[] args;
  
  if (params == null || params.length == 0) {
  args = null;
  } else {
  args = new Class[params.length];
  for (int i=0; i<args.length; i++) {
  args[i] = params[i].toClass();
  }
  }
  
  return lookupMethod(type, mi.getName(), args);
  }