Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » About overriding existing code
About overriding existing code [message #513148] Tue, 09 February 2010 04:43 Go to next message
SonglinPiao  is currently offline SonglinPiao Friend
Messages: 11
Registered: December 2009
Junior Member
Hello, I have now a question . I added much code to gmf generated original code. But now I want to upgrade my ecore file to a new one. In this case, if I generated code again, is it possible I can still have my own latter added codes ? I have alreay done a test. I can still find my own code there , but there are some errors . Is there anyone who has experienced this ? Thanks !!
Re: About overriding existing code [message #513170 is a reply to message #513148] Tue, 09 February 2010 08:14 Go to previous message
Aurélien Pupier is currently offline Aurélien PupierFriend
Messages: 637
Registered: July 2009
Location: Grenoble, FRANCE
Senior Member

Hi,

you need to put @generated NOT annotation on the method that you have modified into your generated code.

BTW I recommend you to separate generated code from your custom code by using providers and modifying templates.

Regards,


Aurélien Pupier - Red Hat
Senior Software Engineer in Fuse Tooling team
Previous Topic:Activate metrics and audits from the gmf generator
Next Topic:Changing anchor location and z-order of connections
Goto Forum:
  


Current Time: Fri Sep 20 04:30:18 GMT 2024

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

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

Back to the top