Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 314255 - [Class Diagram] Containment Cycling Model with the Class Diagram
Summary: [Class Diagram] Containment Cycling Model with the Class Diagram
Status: RESOLVED DUPLICATE of bug 318000
Alias: None
Product: Papyrus
Classification: Modeling
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC All
: P3 critical (vote)
Target Milestone: 0.7.0   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-25 08:39 EDT by Cedric Brun CLA
Modified: 2010-06-25 11:05 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Cedric Brun CLA 2010-05-25 08:39:35 EDT
1. create a new class diagram
2. click on "nodes"=>"Class" and create a class
3. click on "edges"=>"Containment link" and click on the previously created class

Eclipse become unusable, errors are poping up on every action and the error log is filled with Exceptions caused by :

Caused by: java.lang.IllegalStateException: There is a cycle in the containment hierarchy of org.eclipse.uml2.uml.internal.impl.ClassImpl@1cc858 (name: Class0, visibility: <unset>) (isLeaf: false, isAbstract: false) (isActive: false)
at org.eclipse.emf.ecore.util.EcoreUtil.getRootContainer(EcoreUtil.java:811)
at org.eclipse.uml2.common.util.CacheAdapter.addAdapter(CacheAdapter.java:282)
at org.eclipse.uml2.common.util.CacheAdapter.getNonNavigableInverseReferences(CacheAdapter.java:298)
at org.eclipse.uml2.common.util.UML2Util.getNonNavigableInverseReferences(UML2Util.java:1104)

Looks like after this sequence of actions the model is cycling in its containment structure.
Comment 1 Yann Tanguy CLA 2010-06-10 17:02:00 EDT
Containment link must have different element ends

If A contains B, ContainmentLink creation from B to A does not modify containment (the result should be B contains A after ContainmentLink creation).
Comment 2 Yann Tanguy CLA 2010-06-25 11:05:12 EDT
Several bug are open related to the ContainmentLink behavior -> see Bug318000

*** This bug has been marked as a duplicate of bug 318000 ***