BeanUtils来着不同的包,功能也不相同
- org.apache.commons.beanutils.BeanUtils;
BeanUtils.copyProperties(final Object dest, final Object orig)
功能点:Copy property values from the origin bean to the destination bean(从orig对象复制property到dest对象)
- org.springframework.beans.BeanUtils
BeanUtils.copyProperties(Object source, Object target)
功能点:Copy the property values of the given source bean into the target bean.(将source 对象的property复制到target对象)