if (address != null) {
if (address.getId() != null) {
parsed = getDao().find(Address.class, address.getId());
BeanUtils.copyProperties(address, parsed, new String[] {"id"});
}
Province province = address.getProvince();
if ((province != null) && (province.getId() != null)) address.setProvince(getDao().find(Province.class, province.getId()));
AddressType type = address.getType();
if ((type != null) && (type.getId() != null)) address.setType(getDao().find(AddressType.class, type.getId()));
}
return parsed;
}