Phatom node keep referencing a deleted element => save impossible ! [message #199334] |
Tue, 29 July 2008 08:52 |
Eclipse User |
|
|
|
Originally posted by: zippo29.hotmail.fr
Hi all!
I am struggling for days with a problem concerning element deletion and a
phamatm node keeping reference to the deleted element. Here my problem in
more detail hoping someone have a hint to solve it:
1)I have a model: Root<>---As<>---Bs<>---Cs<>---Ds, Root<>---Es ,
E<----->D
2)I created an editor where I display As and Bs contaiment via compartment
|
|
|
Re: Phatom node keep referencing a deleted element => save impossible ! [message #199381 is a reply to message #199334] |
Tue, 29 July 2008 12:49 |
Eclipse User |
|
|
|
Originally posted by: awm_abu.yahoo.com
Hi,
I had a similar issue which involved two different resources.
Are the elements you list below in the same or different resources ?
Also how do you do the deletion ? (using EcoreUtil.delete or something else
?)
thanks
"Mous" <zippo29@hotmail.fr> wrote in message
news:1b422e7e4be0d87824c67879318d6f81$1@www.eclipse.org...
> Hi all!
>
> I am struggling for days with a problem concerning element deletion and a
> phamatm node keeping reference to the deleted element. Here my problem in
> more detail hoping someone have a hint to solve it:
>
> 1)I have a model: Root<>---As<>---Bs<>---Cs<>---Ds, Root<>---Es ,
> E<----->D
> 2)I created an editor where I display As and Bs contaiment via compartment
|
|
|
Re: Phatom node keep referencing a deleted element => save impossible ! [message #199400 is a reply to message #199381] |
Tue, 29 July 2008 15:05 |
Eclipse User |
|
|
|
Originally posted by: zippo29.hotmail.fr
Hi, Thanks for your reply
> Hi,
> I had a similar issue which involved two different resources.
> Are the elements you list below in the same or different resources ?
They are in the same diagram file but as i said through a diagram
partition.
> Also how do you do the deletion ? (using EcoreUtil.delete or something else
> ?)
I do the deletion in the diagram via "delete" key or "delete from model"
and I have the same result.
In fact, I created a command to close(if opened) and supress the
sub-diagram that represents the B node from the resource. A sort of clean
up of the GMFResource.
Then I tried to use the same mechanism for the Cs children present in B
diagram to have acess to the D element and to easy the reuse because I had
other sub diagrams and phatom nodes.
I found that this solution is no use because the editparts instances are
accessible only if the concerned diagram editor is opened.
I tried to send a deleteRequest to the model trying to use the
DeleteCommand mechanism but i failed. I think because the diagram did not
share the same editing domain with the model tree-editor.
I did not try EcoreUtil.delete but I think it will only remove the
references from the GMFResource without using a command and then without
updating the model.
But I will give it a try.
Regards
> thanks
> "Mous" <zippo29@hotmail.fr> wrote in message
> news:1b422e7e4be0d87824c67879318d6f81$1@www.eclipse.org...
>> Hi all!
>>
>> I am struggling for days with a problem concerning element deletion and a
>> phamatm node keeping reference to the deleted element. Here my problem in
>> more detail hoping someone have a hint to solve it:
>>
>> 1)I have a model: Root<>---As<>---Bs<>---Cs<>---Ds, Root<>---Es ,
>> E<----->D
>> 2)I created an editor where I display As and Bs contaiment via compartment
|
|
|
|
Powered by
FUDForum. Page generated in 0.02219 seconds