private static BeanInfo loadBeanInfo(String beanInfoClassName,
        Class<?> beanClass) throws Exception{
        try {
            ClassLoader cl = beanClass.getClassLoader();
            if(cl != null){
                return (BeanInfo) Class.forName(beanInfoClassName, true,
                    beanClass.getClassLoader()).newInstance();
            }
        } catch (Exception e) {
            // fall through
        }
        try {
            return (BeanInfo) Class.forName(beanInfoClassName, true,
                    ClassLoader.getSystemClassLoader()).newInstance();
        } catch (Exception e) {
            // fall through
        }
        return (BeanInfo) Class.forName(beanInfoClassName, true,
                Thread.currentThread().getContextClassLoader()).newInstance();
    }