BeanInfoCache extends CachedLogger { public Map<String, PropertyDescriptor> getPropertyDescriptor(final Class<?> beanClass) { Map<String, PropertyDescriptor> map = getPropertyMap(beanClass); return Collections.unmodifiableMap(map); } private  BeanInfoCache(); static BeanInfoCache getInstance(); BeanInfo getBeanInfo(Class<?> beanClass); BeanInfo getBeanInfo(Class<?> beanClass, Class<?> stopClass); BeanDescriptor getBeanDescriptor(Class<?> beanClass); Map<String, PropertyDescriptor> getPropertyDescriptor(final Class<?> beanClass); PropertyDescriptor getPropertyDescriptor(final Class<?> beanClass, String propertyName); Map<String, MethodDescriptor> getMethodDescriptor(final Class<?> beanClass); MethodDescriptor getMethodDescriptor(final Class<?> beanClass, String methodName);  }
@Test public void getPropertyDescriptor() { Map<String, PropertyDescriptor> propertyMap = BeanInfoCache.getInstance().getPropertyDescriptor(Abean.class); for (Map.Entry<String, PropertyDescriptor> entry : propertyMap.entrySet()) { logger.info(entry.getKey()); logger.info(entry.getValue().getName()); } }