Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Compare » Record changes (Record changes in UML model)
Record changes [message #1748791] Mon, 28 November 2016 15:50 Go to next message
taghreed altamimi is currently offline taghreed altamimiFriend
Messages: 184
Registered: October 2014
Senior Member
Hi,
I need to change UML model(deployment diagram) for example adding more devices,deleting device,moving artifact from device to another or delete device or adding more artifacts.Is there any tool or option that can record the changes that i have made automatically??
i tried to use EMFCompare for ecore models but i have UML models and i tried the option (compare with) i didn't understand how it works .I created two version of deployment diagram S and S2 and i choose the option compare with each other.

Can you please advise me how can i record all changes that have made to UML model.

Thanks,
Taghreed
Re: Record changes [message #1748885 is a reply to message #1748791] Tue, 29 November 2016 17:39 Go to previous messageGo to next message
Philip Langer is currently offline Philip LangerFriend
Messages: 99
Registered: March 2015
Location: Vienna, Austria
Member

Hi Taghreed,

change recording is probably a general EMF question, so you might want to ask the question in the EMF forum too.

You could use the EMF change recorder to capture changes while they are applied. It operates based on the change notification framework of EMF and produces a change description as a result. Thus, you have to put the change recorder on the same model instance that is modified (e.g., the model instance that is managed in the editing domain of the editor, etc.).

Btw, the reason why EMF Compare doesn't show useful results for your case is because it seems that none of the model elements could be matched. So they are shown as deleted and added elements. Are you using XMI:IDs?

Hope that helps,

Philip

--
Philip Langer

Get professional Eclipse developer support:
http://eclipsesource.com/en/services/developer-support/


--
Philip Langer

Get professional Eclipse developer support:
http://eclipsesource.com/en/services/developer-support/

[Updated on: Tue, 29 November 2016 17:40]

Report message to a moderator

Re: Record changes [message #1748902 is a reply to message #1748885] Tue, 29 November 2016 22:08 Go to previous messageGo to next message
taghreed altamimi is currently offline taghreed altamimiFriend
Messages: 184
Registered: October 2014
Senior Member
Hi Philip,
I am using Papyrus Mars on Epsilon and i used Compare with each other option to compare two UML models.For example
If i have two deployment diagram S1,S2
S1Model has device1 and has one artifact
S2Model which represents S1Model with changes such as adding new device let say device2 and then adding new artifact to device1.
So the changes should be :
adding new device device2(packagedElement)
adding new artifact to device1 (nestedClassifier)
When i applied compare with each other i got what is in the picture below (compare with each other)

I don't know if that is the correct way to do comparison and register every change that i have made because i think this is considered two different models with different IDs??
Also I tried to change the model itself ( Stest) i tried to see set of changes i have made so i used compare with local history then the problem that i got that i cannot get the whole changes all at once ,i got group of changes after each save and therefore i need to remember the first state of my model before change and follow each date and time to every change that i made which is not practical,

So i am really confused Sad I need to record the changes that i have made to UML model in order to be able later to propagate that set of changes to another model(LQN).

Please can you help me to be on the right track.

Taghreed.

[Updated on: Tue, 29 November 2016 22:21]

Report message to a moderator

Re: Record changes [message #1749136 is a reply to message #1748902] Fri, 02 December 2016 08:54 Go to previous messageGo to next message
Philip Langer is currently offline Philip LangerFriend
Messages: 99
Registered: March 2015
Location: Vienna, Austria
Member

Hi,

did you attach the correct screenshots? To me, both look equal.

You are using XMI:IDs and, I assume, the IdentityBasedMatcher will be used. Thus, you have to make sure that you only compare two versions of the same model (one is a modification of the other). Because if you compare two independent models, which have the same content, but which have been created separately, the models will have different XMI:IDs and, hence, will not be matched as you expect it. For the IdentityBasedMatcher, different XMI:ID means different EObject, means deletion/addition.

You could try to use git and the builds from collaborative-modeling.org (update sites [1] and [2]). This way you can create commits/branches that contain different states of your model in your git repo, which would allow you to compare those different branches (right-click on the model, compare with, Branch, ...).

Best wishes,

Philip

[1] http://download.eclipse.org/modeling/emf/compare/updates/logical/emf.compare/integration (integration custom build of EMF Compare over custom build of EGit)
[2] http://download.eclipse.org/modeling/emf/compare/updates/egit-logical/integration (integration custom build of EGit)

--
Philip Langer

Get professional Eclipse developer support:
http://eclipsesource.com/en/services/developer-support/


--
Philip Langer

Get professional Eclipse developer support:
http://eclipsesource.com/en/services/developer-support/
Re: Record changes [message #1749174 is a reply to message #1749136] Fri, 02 December 2016 16:29 Go to previous messageGo to next message
taghreed altamimi is currently offline taghreed altamimiFriend
Messages: 184
Registered: October 2014
Senior Member
Thanks for your help:)
Can you take a look on this tutorial and tell me if this is the one that i need to creat commits /branches
https://www.eclipse.org/emf/compare/documentation/latest/tutorial/tutorial.html

Thanks.
Re: Record changes [message #1749291 is a reply to message #1749174] Mon, 05 December 2016 09:00 Go to previous messageGo to next message
Philip Langer is currently offline Philip LangerFriend
Messages: 99
Registered: March 2015
Location: Vienna, Austria
Member

Hi,

yes, this tutorial shows how to use EMF Compare with EGit at the end. You could also check out this tutorial on youtube:

https://www.youtube.com/watch?v=NSCfYAukYgk

Best wishes,

Philip

--
Philip Langer

Get professional Eclipse developer support:
http://eclipsesource.com/en/services/developer-support/


--
Philip Langer

Get professional Eclipse developer support:
http://eclipsesource.com/en/services/developer-support/
Re: Record changes [message #1749444 is a reply to message #1749291] Tue, 06 December 2016 19:03 Go to previous message
taghreed altamimi is currently offline taghreed altamimiFriend
Messages: 184
Registered: October 2014
Senior Member
Thanks
Previous Topic:EMF compare cannot compute model differences
Next Topic:Papyrus model comparison results in a lot of non-existing differences
Goto Forum:
  


Current Time: Tue Nov 12 03:21:20 GMT 2024

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

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

Back to the top