Community
Participate
Working Groups
Created attachment 236459 [details] Files to compare M2: The attachment contains two self-contained files that differ only in the reassignment of UUIDs. EMF Compare reports 2000 differences. There are zero model differences, although if there was an identity comparison option, the xmi:id differences could be reported when xmi:id's are used as the basis opf identity. It is not the case that superclasses have changed.
Our strategy to match elements before comparing them is: - if there are ids (intrinsic or extrinsic), use them, - if there is no, use content-based heuristic matching. This strategy has been implemented because to match by ids is *much* faster than to match based on the objects contents. What we could offer is an action after the initial comparison to let you ask to EMF Compare to recompute the comparison without using the ids (like you can ask to text compare to ignore whitespace). What do you think?
I realize that my test case is a bit wierd; identical model content with 50% xmi:ids equal and 50% regenerated. wierd; well actually it's a bug I'm working on. However xmi:id is locally unique, and arguably a model difference is between two localities, so while discovering xmi:id equality may be a good clue about equality, discovering inequality does not mean difference. So it could be good to pool the xmi:id equalities, then search for more matches structurally. This could be controlled by two menu checkboxes: - Identical xmi:id implies same object (default true) - Distinct xmi:id implies different object (default true) possibly also - Identical ID implies same object (default false) - Distinct ID implies different object (default false) all defaulting to a project and workspace preference.