private void introspectInterfaces(Class<?> beanClass, Class<?> currClass) throws IntrospectionException { for (Class<?> ifc : currClass.getInterfaces()) { if (!ClassUtils.isJavaLanguageInterface(ifc)) { for (PropertyDescriptor pd : getBeanInfo(ifc).getPropertyDescriptors()) { PropertyDescriptor existingPd = this.propertyDescriptorCache.get(pd.getName()); if (existingPd == null || (existingPd.getReadMethod() == null && pd.getReadMethod() != null)) { // GenericTypeAwarePropertyDescriptor leniently resolves a set* write method // against a declared read method, so we prefer read method descriptors here. pd = buildGenericTypeAwarePropertyDescriptor(beanClass, pd); this.propertyDescriptorCache.put(pd.getName(), pd); } } introspectInterfaces(ifc, ifc); } } }
introspectInterfaces(beanClass, currClass); currClass = currClass.getSuperclass();
private void introspectInterfaces(Class<?> beanClass, Class<?> currClass) throws IntrospectionException { for (Class<?> ifc : currClass.getInterfaces()) { if (!ClassUtils.isJavaLanguageInterface(ifc)) { for (PropertyDescriptor pd : getBeanInfo(ifc).getPropertyDescriptors()) { PropertyDescriptor existingPd = this.propertyDescriptorCache.get(pd.getName()); if (existingPd == null || (existingPd.getReadMethod() == null && pd.getReadMethod() != null)) { // GenericTypeAwarePropertyDescriptor leniently resolves a set* write method // against a declared read method, so we prefer read method descriptors here. pd = buildGenericTypeAwarePropertyDescriptor(beanClass, pd); this.propertyDescriptorCache.put(pd.getName(), pd); } } introspectInterfaces(ifc, ifc); } } }
introspectInterfaces(beanClass, currClass); currClass = currClass.getSuperclass();