public static Optional<Method> findMethod(Class<?> clazz, String methodName, Class<?>[] paramsType) {
        if (clazz == null) {
            return Optional.empty();
        }
        final String methodKey = buildMethodKey(clazz, methodName, paramsType);
        try {
            Method method = METHOD_CACHE.get(methodKey);
            if (method != null) {
                return Optional.of(method);
            }
            method = setObjectAccessible(clazz.getDeclaredMethod(methodName, paramsType));
            METHOD_CACHE.put(methodKey, method);
            return Optional.of(method);
        } catch (NoSuchMethodException ex) {
            Optional<Method> method = findSuperClass(clazz, methodName, paramsType);
            if (method.isPresent()) {
                return method;
            }
        }
        return Optional.empty();
    }
@Test
    public void findMethod() {
        final Optional<Method> findMethod = ReflectUtils.findMethod(TestReflect.class, "findMethod", null);
        Assert.assertTrue(findMethod.isPresent());
        final Optional<Method> test = ReflectUtils.findMethod(TestReflect.class, "test", null);
        Assert.assertFalse(test.isPresent());
        final Optional<Method> findMethodWithParam = ReflectUtils
                .findMethod(TestReflect.class, "findMethodWithParam", new Class[]{String.class, int.class});
        Assert.assertTrue(findMethodWithParam.isPresent());
        final Optional<Object> reflect = ReflectUtils.buildWithConstructor(ReflectUtils.class, null, null);
        Assert.assertTrue(reflect.isPresent());
        final Optional<Object> methodCache = ReflectUtils.getFieldValue(reflect.get(), "METHOD_CACHE");
        Assert.assertTrue(methodCache.isPresent() && methodCache.get() instanceof Map);
        Assert.assertFalse(((Map<?, ?>) methodCache.get()).isEmpty());
    }