protected DozerPropertyDescriptor getSrcPropertyDescriptor(Class<?> runtimeSrcClass) { DozerPropertyDescriptor result = this.srcPropertyDescriptorMap.get(runtimeSrcClass); if (result == null) { String srcFieldMapGetMethod = getSrcFieldMapGetMethod(); String srcFieldMapSetMethod = getSrcFieldMapSetMethod(); DozerPropertyDescriptor descriptor = PropertyDescriptorFactory.getPropertyDescriptor(runtimeSrcClass, getSrcFieldTheGetMethod(), getSrcFieldTheSetMethod(), srcFieldMapGetMethod, srcFieldMapSetMethod, isSrcFieldAccessible(), isSrcFieldIndexed(), getSrcFieldIndex(), getSrcFieldName(), getSrcFieldKey(), isSrcSelfReferencing(), getDestFieldName(), getSrcDeepIndexHintContainer(), getDestDeepIndexHintContainer(), classMap.getSrcClassBeanFactory()); this.srcPropertyDescriptorMap.putIfAbsent(runtimeSrcClass, descriptor); result = descriptor; } return result; }
public static void reverseFields(ClassMap source, ClassMap destination) { // reverse the fields destination.setSrcClass(new DozerClass(source.getDestClassName(), source.getDestClassToMap(), source.getDestClassBeanFactory(), source.getDestClassBeanFactoryId(), source.getDestClassMapGetMethod(), source.getDestClassMapSetMethod(), source.getDestClass().getCreateMethod(), source.isDestMapNull(), source.isDestMapEmptyString(), source.getDestClass().isAccesible())); destination.setDestClass(new DozerClass(source.getSrcClassName(), source.getSrcClassToMap(), source.getSrcClassBeanFactory(), source.getSrcClassBeanFactoryId(), source.getSrcClassMapGetMethod(), source.getSrcClassMapSetMethod(), source.getSrcClass().getCreateMethod(), source.isSrcMapNull(), source.isSrcMapEmptyString(), source.getSrcClass().isAccesible())); destination.setType(source.getType()); destination.setWildcard(source.isWildcard()); destination.setTrimStrings(source.isTrimStrings()); destination.setDateFormat(source.getDateFormat()); destination.setRelationshipType(source.getRelationshipType()); destination.setStopOnErrors(source.isStopOnErrors()); destination.setAllowedExceptions(source.getAllowedExceptions()); destination.setSrcClassCreateMethod(source.getDestClassCreateMethod()); destination.setDestClassCreateMethod(source.getSrcClassCreateMethod()); if (StringUtils.isNotEmpty(source.getMapId())) { destination.setMapId(source.getMapId()); } }
source.getDestClass().getCreateMethod(), source.isDestMapNull(), source.isDestMapEmptyString(), source.getDestClass().isAccesible())); destination.setDestClass(new DozerClass(source.getSrcClassName(), source.getSrcClassToMap(), source.getSrcClassBeanFactory(), source.getSrcClassBeanFactoryId(), source.getSrcClassMapGetMethod(), source.getSrcClassMapSetMethod(), source.getSrcClass().getCreateMethod(),
public DozerPropertyDescriptor getSrcPropertyDescriptor(Class<?> runtimeSrcClass) { DozerPropertyDescriptor result = this.srcPropertyDescriptorMap.get(runtimeSrcClass); if (result == null) { String srcFieldMapGetMethod = getSrcFieldMapGetMethod(); String srcFieldMapSetMethod = getSrcFieldMapSetMethod(); DozerPropertyDescriptor descriptor = PropertyDescriptorFactory.getPropertyDescriptor(runtimeSrcClass, getSrcFieldTheGetMethod(), getSrcFieldTheSetMethod(), srcFieldMapGetMethod, srcFieldMapSetMethod, isSrcFieldAccessible(), isSrcFieldIndexed(), getSrcFieldIndex(), getSrcFieldName(), getSrcFieldKey(), isSrcSelfReferencing(), getDestFieldName(), getSrcDeepIndexHintContainer(), classMap.getSrcClassBeanFactory()); this.srcPropertyDescriptorMap.putIfAbsent(runtimeSrcClass, descriptor); result = descriptor; } return result; }
destination.setDestClass(new DozerClass(source.getSrcClassName(), source.getSrcClassToMap(), source.getSrcClassBeanFactory(), source.getSrcClassBeanFactoryId(), source.getSrcClassMapGetMethod(),
public DozerPropertyDescriptor getSrcPropertyDescriptor(Class<?> runtimeSrcClass) { DozerPropertyDescriptor result = this.srcPropertyDescriptorMap.get(runtimeSrcClass); if (result == null) { String srcFieldMapGetMethod = getSrcFieldMapGetMethod(); String srcFieldMapSetMethod = getSrcFieldMapSetMethod(); DozerPropertyDescriptor descriptor = PropertyDescriptorFactory.getPropertyDescriptor(runtimeSrcClass, getSrcFieldTheGetMethod(), getSrcFieldTheSetMethod(), srcFieldMapGetMethod, srcFieldMapSetMethod, isSrcFieldAccessible(), isSrcFieldIndexed(), getSrcFieldIndex(), getSrcFieldName(), getSrcFieldKey(), isSrcSelfReferencing(), getDestFieldName(), getSrcDeepIndexHintContainer(), classMap.getSrcClassBeanFactory()); this.srcPropertyDescriptorMap.putIfAbsent(runtimeSrcClass, descriptor); result = descriptor; } return result; }