public static Object judgeCustomThrowableForGenericObject(Object appObject) {
        if (!GENERIC_THROW_EXCEPTION || appObject == null) {
            return appObject;
        }
        if (!(appObject instanceof GenericObject)) {
            return appObject;
        }
        for (String field : THROWABLE_FIELDS) {
            if (!((GenericObject) appObject).hasField(field)) {
                return appObject;
            }
        }
        return new RuntimeException(
            "occur business exception, but type=" + ((GenericObject) appObject).getType() +
                " class is not found, error: " + appObject);
    }
@Test
    public void testJudgeCustomThrowable() throws Exception {
        setGenericThrowException(true);
        try {
            Assert.assertNull(judgeCustomThrowableForGenericObject(null));
            Object o = new Object();
            Assert.assertEquals(o, judgeCustomThrowableForGenericObject(o));
            GenericObject genericObject = new GenericObject("");
            Assert.assertEquals(genericObject, judgeCustomThrowableForGenericObject(genericObject));
            genericObject.putField("xxx", "yyy");
            Assert.assertEquals(genericObject, judgeCustomThrowableForGenericObject(genericObject));

            genericObject.putField("cause", "yyy");
            genericObject.putField("detailMessage", "yyy");
            genericObject.putField("stackTrace", "yyy");
            genericObject.putField("suppressedExceptions", "yyy");
            Assert.assertTrue(judgeCustomThrowableForGenericObject(genericObject) instanceof RuntimeException);
        } finally {
            setGenericThrowException(false);
        }
    }