Dave <sanxion200..ahoo.com> wrote:
> Are there any built in methods to create a copy of a
> DataObject? I want to add a new row that is the same
> as a prior. The key would be the only difference.
I think you could do it by iterating through the "values" protected
DataObject map.
Create a new object.
Iterate through values.
value = readProperty(key)
writeProperty(key, values)
You might find that readPropertyDirectly and writePropertyDirectly will work
better for you.
Supporting something like this in DataObjectUtils would be useful, so you
could submit an enhancement request (and probably a patch) in the Jira issue
tracker to get it into a future version of Cayenne.
-Mike
This archive was generated by hypermail 2.0.0 : Tue Dec 28 2004 - 10:28:12 EST