public static Object invokeExactStaticMethod(final Class<?> cls, final String methodName,
            Object[] args, Class<?>[] parameterTypes)
            throws NoSuchMethodException, IllegalAccessException,
            InvocationTargetException {
        args = ArrayUtils.nullToEmpty(args);
        parameterTypes = ArrayUtils.nullToEmpty(parameterTypes);
        final Method method = getAccessibleMethod(cls, methodName, parameterTypes);
        if (method == null) {
            throw new NoSuchMethodException("No such accessible method: "
                    + methodName + "() on class: " + cls.getName());
        }
        return method.invoke(null, args);
    }
public static Object invokeExactStaticMethod ( final Class < ? > cls , final String methodName , Object [ ] args , Class < ? > [ ] parameterTypes ) throws NoSuchMethodException , IllegalAccessException , InvocationTargetException { args = ArrayUtils . nullToEmpty ( args ) ; parameterTypes = ArrayUtils . nullToEmpty ( parameterTypes ) ; final Method method = getAccessibleMethod ( cls , methodName , parameterTypes ) ; if ( method == null ) { throw new NoSuchMethodException ( "No such accessible method: " + methodName + "() on class: " + cls . getName ( ) ) ; } return method . invoke ( null , args ) ; }
<p>Invokes a {@code static} method whose parameter types match exactly the parameter
types given.</p>

<p>This uses reflection to invoke the method obtained from a call to
{@link #getAccessibleMethod(Class, String, Class[])}.</p>

@param cls invoke static method on this class
@param methodName get method with this name
@param args use these arguments - treat {@code null} as empty array
@param parameterTypes match these parameters - treat {@code null} as empty array
@return The value returned by the invoked method

@throws NoSuchMethodException if there is no such accessible method
@throws InvocationTargetException wraps an exception thrown by the
method invoked
@throws IllegalAccessException if the requested method is not accessible
via reflection