eContainer in other resource [message #1708161] |
Mon, 14 September 2015 06:07  |
Eclipse User |
|
|
|
Hi all,
I have a model A.xmi that contains a model B.xmi throught a containment reference that is a proxy. Both resources (A.xmi and B.xmi) are load and inside a ResourceSet. The thing is that I want to obtain the eContainer from an EObject y (the first element of B.xmi), but the y.eContainer is null and taking into account the definition of eContainer would be right thing. I've tried some things but without result, so I would like to know, how to obtain the eContainer in this case?
Thanks for any help.
Cheers,
Anthony
|
|
|
|
|
Re: eContainer in other resource [message #1708274 is a reply to message #1708242] |
Tue, 15 September 2015 03:14  |
Eclipse User |
|
|
|
Anthony,
Unless there is a serialized reference to the container, the object
being contained has no knowledge of its container until the container
resolves the proxy to the child. On a modeled container reference can
be serialized...
On 14/09/2015 11:48 PM, Anthony Garmendia wrote:
> Hi Ed,
>
> Thank you very much for the reply. The thing is that I don't want to
> force that the Ecore Metamodel need to define an opposite for the
> containment reference. I would like to get the eContainer when the
> opposite is not defined.
> There is any way to get the eContainer without define this opposite
> containment reference?
> Cheers,
> Anthony
|
|
|
Powered by
FUDForum. Page generated in 0.26515 seconds