Hello all!
Lets say I have an existing value object myPersonValue and create a new value object myCarValue = new CarValue() and do myPersonValue.addCarValue(myCarValue).
Then (not yet persisted, still the same objects) the user decides to change the color of myCarValue(), e.g. myCarValue.setColor("white"). So I do myPersonValue.updateCarValue(myCarValue).
Bang!
myPersonValue.updateCarValue(myCarValue) adds myCarValue to myPersonValue.updatedCarValues, what it shouldn't. Trying to persist this, findByPrimaryKey is called with a null agument, etc.
So why does it do so?
myPersonValue.updateCarValue(myCarValue) tests if myPersonValue.addedCarValues.contains(myCarValue). This returns *false*! Why? Because addedCarValues is a HashSet and the hash value of myCarValue has changed because of the color change.
Can someone explain this? And how is it supposed to be used?
please help!
thanx! Marcus
------------------------------------------------------- This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools! Get your free copy of BEA WebLogic Workshop 8.1 today. http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click _______________________________________________ xdoclet-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/xdoclet-user