Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 361666 - [EMF Compare UML] Update Reference difference target to the wrong targets when target is a stereotype
Summary: [EMF Compare UML] Update Reference difference target to the wrong targets whe...
Status: CLOSED FIXED
Alias: None
Product: EMFCompare
Classification: Modeling
Component: Core (show other bugs)
Version: 1.3   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: EMF Compare CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 360757
Blocks:
  Show dependency tree
 
Reported: 2011-10-21 10:55 EDT by Arthur Daussy CLA
Modified: 2013-01-17 08:32 EST (History)
1 user (show)

See Also:


Attachments
Models to reproduce (3.47 KB, application/x-zip-compressed)
2011-10-21 10:55 EDT, Arthur Daussy CLA
no flags Details
Possible correction (3.33 KB, patch)
2011-10-21 11:02 EDT, Arthur Daussy CLA
laurent.goubet: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Arthur Daussy CLA 2011-10-21 10:55:25 EDT
Created attachment 205733 [details]
Models to reproduce

When updating a stereotype reference to another stereotype. The diff element always have as targets the stereotypes application elements. However if the EReference which has been updated belong the to based element then the display is not correct.

How to reproduce:
 -> Use the two models given in attachment.
 -> See in the Structured View the values displayed are not correct:
    ... Dimension to Dimension .. instead of ... Dimension0 to Dimension1...

The problem can often appear in SysML with an Value Type element which reference an Dimension Element.
Comment 1 Arthur Daussy CLA 2011-10-21 11:02:47 EDT
Created attachment 205735 [details]
Possible correction

The following path could be a fix for this bug.
Comment 2 Laurent Goubet CLA 2011-10-26 04:32:41 EDT
The fix seems good and does not provoke regressions in the current test suite. There might be other situations where we would need to "browse" to the "base" element instead of staying on the stereotype application, but for now that will do.

The patch will be pushed on master with a few modifications :

- author added in copyright notice of the changed class
- name of the method changed from "setCorrectTarget" to "setTargets"

before I commit though, I need to make sure of what you'd rather see in the copyright notice :

[...]
 * Contributors:
 *     Obeo - initial API and implementation
 *     Arthur Daussy (Atos) - [361666] Fixing target of stereotype application differences
 *******************************************************************************/
[...]

Should it be
- Arthur Daussy (Atos)
- Arthur Daussy (Atos Origin)
- Atos
... ?
Comment 3 Arthur Daussy CLA 2011-10-26 06:54:02 EDT
Arthur Daussy (Atos) is perfect.
Sorry I have forgotten to do it. I will for the next patch.
Comment 4 Laurent Goubet CLA 2011-10-26 08:38:31 EDT
> Sorry I have forgotten to do it. I will for the next patch.

No problem, this is hardly difficult for me to add :).

The patch has been pushed to master and will be available in the next 1.3 build.
Comment 5 Laurent Goubet CLA 2013-01-17 08:32:15 EST
batch-closing a bunch of "RESOLVED" bugs.