I was just wonding if anyone has given any thought to how one would be to modify the synchronize method on the EntityGraph such that it also synchronizes adds and deletes. It seems like it should be possible to:
- Compare the src and destination entitygraphs
- Determine those entitys that aren't present in the destination (but are in the source) and precreate an item in the destination object graph.
- Determine those items in the destination, but not in the source and remove those items from the destination object graph.
Once these steps are complete, then the source and destination entity object graphs would be consistent which means that the existing synchronize method would do the remainder of the work.
Does anyone have any thoughts on this?