// already mapped
if (!destinationIsMap && classMap.getFieldMapUsingDest(fieldName, true) != null) {
continue;
}
FieldMap fieldMap = new MapFieldMap(classMap);
DozerField srcField = new DozerField(MappingUtils.isSupportedMap(srcClass) ? DozerConstants.SELF_KEYWORD : fieldName, null);
srcField.setKey(fieldName);
if (StringUtils.isNotEmpty(classMap.getSrcClassMapGetMethod())
|| StringUtils.isNotEmpty(classMap.getSrcClassMapSetMethod())) {
srcField.setMapGetMethod(classMap.getSrcClassMapGetMethod());
srcField.setMapSetMethod(classMap.getSrcClassMapSetMethod());
srcField.setName(DozerConstants.SELF_KEYWORD);
}
DozerField destField = new DozerField(MappingUtils.isSupportedMap(destClass) ? DozerConstants.SELF_KEYWORD : fieldName,
null);
srcField.setKey(fieldName);
if (StringUtils.isNotEmpty(classMap.getDestClassMapGetMethod())
|| StringUtils.isNotEmpty(classMap.getDestClassMapSetMethod())) {
destField.setMapGetMethod(classMap.getDestClassMapGetMethod());
destField.setMapSetMethod(classMap.getDestClassMapSetMethod());
destField.setName(DozerConstants.SELF_KEYWORD);
}
fieldMap.setSrcField(srcField);
fieldMap.setDestField(destField);
classMap.addFieldMapping(fieldMap);
}
return true;
}