Skip to main content



      Home
Home » Modeling » Compare » [EMF Compare] Ignore order in EMFCompare
[EMF Compare] Ignore order in EMFCompare [message #1046737] Mon, 22 April 2013 05:49 Go to next message
Eclipse UserFriend
I'm comparing ecore models and the following example returns an EMF Compare move. In the following example I move the name Attribute. The same happens when I change the order of the classes in the ecore model.

original code:
<eClassifiers xsi:type="ecore:EClass" name="Author">
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="test" eType="#//Book" eOpposite="#//Book/test"/>
  </eClassifiers>


moved "name" element
<eClassifiers xsi:type="ecore:EClass" name="Author">
    <eStructuralFeatures xsi:type="ecore:EReference" name="test" eType="#//Book" eOpposite="#//Book/test"/>
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
  </eClassifiers>


They are not breaking the generated code. Is it possible in EMF Compare to set these changes to be ignored?
Re: [EMF Compare] Ignore order in EMFCompare [message #1047411 is a reply to message #1046737] Tue, 23 April 2013 03:07 Go to previous messageGo to next message
Eclipse UserFriend
Aleksandar,

EMF Compare does not detect "changes that break the generated code". It compares the two given models and detects differences between them, without any assumption that these models are used to generated code (and without assuming that this will be the "default" generated code). Ordering differences will be detected on all "ordered" features, as well as on "containment" features.

That being said, these differences can be ignored. Please see the FAQ on that point.

Laurent Goubet
Obeo
Re: [EMF Compare] Ignore order in EMFCompare [message #1047471 is a reply to message #1046737] Tue, 23 April 2013 04:52 Go to previous message
Eclipse UserFriend
Thanks! That was exactly what I wanted.
Previous Topic:Logical model compare (Compare 1.3.1, with SVN)
Next Topic:[EMF Compare] Compute degree of similarity
Goto Forum:
  


Current Time: Sat Jul 12 17:28:45 EDT 2025

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

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

Back to the top