Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » "Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or its (error when generating gmfgen)
"Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or its [message #630866] Tue, 05 October 2010 11:52 Go to next message
Mickel  is currently offline Mickel Friend
Messages: 4
Registered: September 2010
Junior Member
Hello,
i have a problem that i can't resole:
When i'm generating .gmfgen , i have this error:
*Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or its super-class .
i know it means that my top node elements must have a direct relation to the root element of my diagram or to its super class.
but if i do that,my xml's file (describing my schema) generated will be changed an this element will be contained in root while i want it to be contained in another node.
would you help me please!
Re: "Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or [message #792342 is a reply to message #630866] Mon, 06 February 2012 22:39 Go to previous messageGo to next message
Amir H. Moin is currently offline Amir H. MoinFriend
Messages: 6
Registered: February 2012
Junior Member
Hi all,

I've got the same problem using Eclipse Indigo.

Any help would be appreciated! Thanks in advance.
Re: "Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or [message #792467 is a reply to message #792342] Tue, 07 February 2012 02:41 Go to previous messageGo to next message
Michael Golubev is currently offline Michael GolubevFriend
Messages: 383
Registered: July 2009
Senior Member
Hello,

Can't you just, hum, choose the containment feature for the problem top level node from those available in the metaclass chosen for diagram element or in one of its super classes?

You may have to post some more details here, otherwise the warning message you are getting just precisely describes the problem you have.

Regards,
Michael "Borlander" Golubev
at Montages Think Tank, Prague, Czech Republic
Montages AG, Zürich, Switzerland

Re: "Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or [message #798973 is a reply to message #792467] Wed, 15 February 2012 09:42 Go to previous messageGo to next message
Amir H. Moin is currently offline Amir H. MoinFriend
Messages: 6
Registered: February 2012
Junior Member
Hello,

I apologize for the delay...

Please consider the situation in more details:

For our Multi-agent system model, we have various diagrams like Agent diagram, Collaboration diagram, Behavior diagram, etc. In Eclipse Helios there were no errors. However, using Eclispe Indigo, for some of the diagrams there are errors. Getting more into the details, one could understand that the errors have occurred only in the following scenario:

If the containment feature of any of the Top Node Reference of the GMF Mapping for a diagram is something other than MultiagentSystem.agent or MultiagentSystem.behavior or MultiagentSystem.... (i.e. something without a direct link to the root element which is MultiagentSystem)

For example, the containment feature of one of the Top Node References in the Collaboration diagram is Organization. ... instead of MultiagentSystem. ... (the root element. ...) which has probably been expected and thus has caused the following errors:

'Containment Feature' must reference the same class or super type of 'Domain Meta Element' of the referenced node

Node label meta features must be owned by the node 'Meta Class' or its super-classes

Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or its super-class

It would be unreasonable if one is forced to always relate everything with a direct link to the root element of the diagram, i.e. MultiagentSystem in our case.

Any help is appreciated. Thanks in advance.

Best regards.

Re: "Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or [message #946514 is a reply to message #798973] Tue, 16 October 2012 08:58 Go to previous message
Amir H. Moin is currently offline Amir H. MoinFriend
Messages: 6
Registered: February 2012
Junior Member
Updates: (For anyone who is experiencing the same problem)

1. Please follow up the issue here:

http://www.eclipse.org/forums/index.php/t/293896/

2. What I already reported regarding the occurrence of this issue only in Eclipse "Indigo" is not true. After doing a fresh installation of "Helios" it turned out that it also happens in Helios. Moreover, in the latest release of Eclipse, i.e. Juno the situation is the same.

So, it is not a problem of Eclipse, but it is rather a constraint of GMF for the containments in our semantic models which we should follow to resolve the error.

Finally, even if you do not resolve the error, you just get a warning for generating the diagram code, but by ignoring that warning you could generate the code and there would be no serious problem at all. However, you would need to then manually modify the generated code and mark those methods as @generated NOT. Please see the above mentioned link for more information.

[Updated on: Wed, 17 October 2012 07:37]

Report message to a moderator

Previous Topic:Place a custom figure into a compartment
Next Topic:Top level node 'Containment Feature' must be available in the diagram 'Domain Element' or its super-
Goto Forum:
  


Current Time: Fri Apr 26 20:32:49 GMT 2024

Powered by FUDForum. Page generated in 0.03809 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top