code: public static Object invokeMethod(Object object, Method method, Object... args) throws Throwable {
          try {
              return method.invoke(object, args);
          } catch (InvocationTargetException e) {
              throw e.getTargetException();
          }
      }
docs: Invokes the method of the specified object with some method arguments.