|[CDO] Best Practices: how to save a CDObject with unsaved references [message #896266]
||Tue, 17 July 2012 19:39
| Paco Blanco
Registered: June 2012
In my case, I need to create a "complex" graph object model from scratch. For example, a country has localized names. Each localized name makes references to a language and a country so there are loops in the graph. In this example, these classes are connected logically by EMF EReference links.|
When I call to a service to persist one country from the model by CDO client, this service does know nothing if other ereferences associated entities are yet saved into a resource or not. So if service adds the country to a resource and does commit, an exception could be thrown because some of the associated entities are not included in any resource.
Is the situation to try to persist only one country a bad practice?
What is the best practice to persist the graph model?
Does CDO provide a method to include "automatically" ereference linked objects that are not yet included into any resource?
[Updated on: Tue, 17 July 2012 20:13]
Report message to a moderator
Powered by FUDForum
. Page generated in 0.02067 seconds