Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 471134

Summary: [tool] Elementtype naming problem upon creation.
Product: [Modeling] Papyrus-rt Reporter: Onder Gurcan <onder.gurcan>
Component: toolAssignee: Quentin Le Menez <quentin.lemenez>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: asma.smaoui, charles, papyrus-bugs, peter.cigehn, rschnekenburger
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Bug Depends on: 471135    
Bug Blocks:    

Description Onder Gurcan CLA 2015-06-26 09:42:35 EDT
When an new element is created, it is not possible set its name inside its correspnding EditHelperAdvice. Another advice, executed always after this advice, is overriding the given name.
Comment 1 Peter Cigehn CLA 2016-02-05 10:21:01 EST
For my understanding, what is left within the scope of this Bugzilla and which impact does that have on Papyrus-RT? Can we simply close it? It still depends on an open Bugzilla on Papyrus, Bug 471135. Can that one be closed also, or is that still an issue?
Comment 2 smaoui asma CLA 2016-03-07 10:21:50 EST
Hello, yes I noticed this when fixing Bug 484638. In fact, the ApplySterotype command override the name , it is executed after the configure command. to disable this, there is a boolean property "Update name" in the Apply Steroptype Configure Advise that should be set to false.
Comment 3 Christian Damus CLA 2016-05-04 14:20:31 EDT
As far as parts and ports are concerned, I have fixed this problem in the context of bug 474481.

In my opinion, the edit-helper associated with an element-type should not be responsible for auto-naming of elements.  Rather, the auto-naming should be the responsibility of an advice.  This is in part, at least, because advice can be inherited by specializing element-types, whereas the edit-helper functionality is not inherited.  This is why ports were not getting the correct name behaviour, because they are all one of five different specializations of RTPort and so didn't get the after-set-type behaviour provided by the RTPort edit-helper.

So, in bug 474481, I moved the setting of the name according to the type out of the edit-helpers and into inheritable advices.  There was still a problem with multiple advices attempting to set the name (including one inherited from Papyrus), but I managed to overcome that.  Still, it would be much better if the before/after ordering constraints of advices in the configurations model worked properly (see bug 491783).
Comment 4 Remi Schnekenburger CLA 2016-07-20 09:48:39 EDT
Set as won't fix, as there is not a real bug underneath this precise task.

If some concrete bug has to be worked on, a new bug will be opened.
Comment 5 Charles Rivet CLA 2017-01-31 16:42:36 EST
Batch closing of old, fixed bugs