|Removing EObject from EMF Resource with RemoveCommand [message #763242]
||Fri, 09 December 2011 07:14
| Ricky de Klerck
Registered: January 2011
We're building an example application which is build with EMF/Teneo/Hibernate. We only have one object in our EMF model named "Person". We load our objects by making an EMF Resource. I know we can observe this Resource and use it as input for our TableViewer like this:
This works great, but we when we want to delete a Person from this Resource we're facing a problem. We want to do this through an editingdomain so we should use a Command. Before we always created a RemoveCommand, but now we don't have any StructuralFeature because we only have one Object.
How can we achieve that a Person is removed from a Resource with a Command/EditingDomain. Or is it necessary to have a top element which holds (containment) all the persons? This way we obviously can call a StructuralFeature.. But we don't want this if it isn't necessary.
Thanks in advance.
Ricky de Klerck
Powered by FUDForum
. Page generated in 0.01904 seconds