I've attempted to write a method to copy the non-collection fields of a proxy POJO to another, as defined by the mapping.
To do this, I use Property.getGetter() on the field mapping and then apply that getter to obtain the original value, the apply an obtained setter to set the value in the target POJO.
This seems to work except for those fields that use field access. What's the correct way to proceed in this case? Am I on the right track at all? And how can my method determine which fields use field access and which use accessors?
Thanks, Elly
Last edited by eshevin on Sat Nov 26, 2011 10:53 pm, edited 1 time in total.
|