/** * Obtain a lazily initialized CachedIntrospectionResults instance * for the wrapped object. */ private CachedIntrospectionResults getCachedIntrospectionResults() { if (this.cachedIntrospectionResults == null) { this.cachedIntrospectionResults = CachedIntrospectionResults.forClass(getWrappedClass()); } return this.cachedIntrospectionResults; }
@Override public void setWrappedInstance(Object object, @Nullable String nestedPath, @Nullable Object rootObject) { super.setWrappedInstance(object, nestedPath, rootObject); setIntrospectionClass(getWrappedClass()); }
/** * Obtain a lazily initialized CachedIntrospectionResults instance * for the wrapped object. */ private CachedIntrospectionResults getCachedIntrospectionResults() { if (this.cachedIntrospectionResults == null) { this.cachedIntrospectionResults = CachedIntrospectionResults.forClass(getWrappedClass()); } return this.cachedIntrospectionResults; }
@Override public void setWrappedInstance(Object object, @Nullable String nestedPath, @Nullable Object rootObject) { super.setWrappedInstance(object, nestedPath, rootObject); setIntrospectionClass(getWrappedClass()); }
@Override public void registerCustomEditors(PropertyEditorRegistry registry) { if (!(registry instanceof BeanWrapperImpl)) { return; } BeanWrapperImpl beanWrapper = (BeanWrapperImpl) registry; Class<?> clazz = null; try { clazz = Class.forName(SchedulerFactoryBean, true, registry.getClass().getClassLoader()); } catch (Throwable e) { LOGGER.info("cannot find class for " + SchedulerFactoryBean, e); } if (null == clazz || null == beanWrapper.getWrappedClass() || !clazz.isAssignableFrom(beanWrapper.getWrappedClass())) { return; } registry.registerCustomEditor(Object.class, "triggers", new QuartzSchedulerBeanTargetEditor(context)); } }
@Override public void registerCustomEditors(PropertyEditorRegistry registry) { if (!(registry instanceof BeanWrapperImpl)) { return; } BeanWrapperImpl beanWrapper = (BeanWrapperImpl) registry; Class<?> clazz = null; try { clazz = Class.forName(SchedulerFactoryBean, true, registry.getClass().getClassLoader()); } catch (Throwable e) { LOGGER.info("cannot find class for " + SchedulerFactoryBean, e); } if (null == clazz || null == beanWrapper.getWrappedClass() || !clazz.isAssignableFrom(beanWrapper.getWrappedClass())) { return; } registry.registerCustomEditor(Object.class, "triggers", new QuartzSchedulerBeanTargetEditor(context)); } }
/** * Get and modify the PropertyDescriptors associated with the BeanWrapper. * @param bwrap */ protected PropertyDescriptor[] getPropertyDescriptors(BeanWrapperImpl bwrap) { PropertyDescriptor[] descriptors = bwrap.getPropertyDescriptors(); for(PropertyDescriptor pd : descriptors) { if (DescriptorUpdater.class.isAssignableFrom(bwrap.getWrappedClass()) ) { ((DescriptorUpdater) bwrap.getWrappedInstance()).updateDescriptor(pd); } else { defaultUpdateDescriptor(pd); } } return descriptors; }
/** * Obtain a lazily initializted CachedIntrospectionResults instance * for the wrapped object. */ private CachedIntrospectionResults getCachedIntrospectionResults() { Assert.state(this.object != null, "BeanWrapper does not hold a bean instance"); if (this.cachedIntrospectionResults == null) { this.cachedIntrospectionResults = CachedIntrospectionResults.forClass(getWrappedClass()); } return this.cachedIntrospectionResults; }
@Override public String toString() { return String.format("%s backed by %s, defining options [%s]", getClass().getSimpleName(), beanWrapper.getWrappedClass(), options); }
public String toString() { StringBuffer sb = new StringBuffer("BeanWrapperImpl: wrapping class ["); sb.append(getWrappedClass().getName()).append("]"); return sb.toString(); }
/** * Obtain a lazily initializted CachedIntrospectionResults instance * for the wrapped object. */ private CachedIntrospectionResults getCachedIntrospectionResults() { Assert.state(getWrappedInstance() != null, "BeanWrapper does not hold a bean instance"); if (this.cachedIntrospectionResults == null) { this.cachedIntrospectionResults = CachedIntrospectionResults.forClass(getWrappedClass()); } return this.cachedIntrospectionResults; }
@Override public void registerCustomEditors(PropertyEditorRegistry registry) { if (!(registry instanceof BeanWrapperImpl)) { return; } BeanWrapperImpl beanWrapper = (BeanWrapperImpl) registry; Class<?> clazz = null; try { clazz = Class.forName(SchedulerFactoryBean, true, registry.getClass().getClassLoader()); } catch (Throwable e) { LOGGER.info("cannot find class for " + SchedulerFactoryBean, e); } if (null == clazz || null == beanWrapper.getWrappedClass() || !clazz.isAssignableFrom(beanWrapper.getWrappedClass())) { return; } registry.registerCustomEditor(Object.class, "triggers", new QuartzSchedulerBeanTargetEditor(context)); } }
if (propertyType == null) { if (!ignoreUnkown) { throw new IllegalArgumentException("Unkown field " + fieldName + " on type " + bw.getWrappedClass());
@Override public void setWrappedInstance(Object object, String nestedPath, Object rootObject) { super.setWrappedInstance(object, nestedPath, rootObject); setIntrospectionClass(getWrappedClass()); }
/** * Get and modify the PropertyDescriptors associated with the BeanWrapper. * @param bwrap */ protected PropertyDescriptor[] getPropertyDescriptors(BeanWrapperImpl bwrap) { PropertyDescriptor[] descriptors = bwrap.getPropertyDescriptors(); for(PropertyDescriptor pd : descriptors) { if (DescriptorUpdater.class.isAssignableFrom(bwrap.getWrappedClass()) ) { ((DescriptorUpdater) bwrap.getWrappedInstance()).updateDescriptor(pd); } else { defaultUpdateDescriptor(pd); } } return descriptors; }
|| Calendar.class.isAssignableFrom(value.getClass())) { SimpleDateFormat formatter = getDateFormatter(datePatterns, dateFormatters, entityBean.getWrappedClass(), unescapedFieldName); if (formatter != null) {
|| Calendar.class.isAssignableFrom(value.getClass())) { SimpleDateFormat formatter = getDateFormatter(datePatterns, dateFormatters, entityBean.getWrappedClass(), unescapedFieldName); if (formatter != null) {