diff --git a/src/com/esotericsoftware/reflectasm/MethodAccess.java b/src/com/esotericsoftware/reflectasm/MethodAccess.java index 2bf8f0e..d0de66d 100644 --- a/src/com/esotericsoftware/reflectasm/MethodAccess.java +++ b/src/com/esotericsoftware/reflectasm/MethodAccess.java @@ -20,6 +20,11 @@ public abstract class MethodAccess { abstract public Object invoke (Object object, int methodIndex, Object... args); + /** Invokes the method with the specified name and the specified param types. */ + public Object invoke (Object object, String methodName, Class[] paramTypes, Object... args) { + return invoke(object, getIndex(methodName, paramTypes), args); + } + /** Invokes the first method with the specified name and the specified number of arguments. */ public Object invoke (Object object, String methodName, Object... args) { return invoke(object, getIndex(methodName, args.length), args);