Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Copying GMF projects
Copying GMF projects [message #729440] Mon, 26 September 2011 08:03 Go to next message
Iban Ayestaran is currently offline Iban AyestaranFriend
Messages: 58
Registered: September 2011
Member
Hi!
I am having some problems when I try to copy a GMF project. By now, I have done a project (v1.0) which works fine, but I need to improve it. To do so, I wanted to copy the existing project into another one, and change its name. Is there an easy way to do so?
By now, I made the following steps, but the graphical tool it generates becames unusable, because it is forbidden to draw anything!:
1. Create a new empty project, named "Project_v1.1".
2. Copy-paste the .ecore, .ecore_diagram, .gmftool and .gmfgraph files into the new project.
3. Change their names into "Project_v1.1.ecore", "Project_v1.1.ecore_diagram" and so on.
4. Open "Project_v1.1.ecore", and in the properties of the package, change the values into "Project_v1_1" and "http://Project_v1_1".
5. Open the "Project_v1.1.ecore_diagram" as text and replace all the "Project_v1.0" strings by "Project_v1.1". When I save that, I can again see the diagram with the diagram editor.
6. Generate the .genmodel, and from there, generate the model code, the edit code and the editor code.
7. In the GMF dashboard, select the .ecore, .genmodel, .gmftool and .gmfgraph files, and derive the .gmfmap from them.
8. Set the .gmfmap properties exactly as they where in the v1.0 project.
9. Generate the .gmfgen.
10. Generate the diagram editor.

I wouldn't care to make all those steps all the time if it worked, but the problem is that if I run the .diagram project, it generates a project where I can draw nothing! Is there an easier way, or just a way where the new project works??

Thanks in advance!
Re: Copying GMF projects [message #729972 is a reply to message #729440] Tue, 27 September 2011 11:51 Go to previous message
Iban Ayestaran is currently offline Iban AyestaranFriend
Messages: 58
Registered: September 2011
Member
Hi everybody!

I noticed now what my problem was: I had a lot of projects in my project explorer (Project_v1.0, Project_v1.1, Project_v1.2, ...). So when I launched any of the '.diagram' projects as Eclipse applications, the diagram editor used to became crazy and I couldn't draw anything.

The solution was as simple as just deleting the rest of the projects and launching the 'Project_v1.1.diagram' project while only the 'Project_v1.1', 'Project_v1.1.edit', 'Project_v1.1.editor' and 'Project_v1.1.diagram' where visible in the project explorer.

Bye!
Previous Topic:XML generated by the gmf editor
Next Topic:duplicate method/field after GenerateDiagramEditor
Goto Forum:
  


Current Time: Thu Mar 28 22:07:46 GMT 2024

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

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

Back to the top