Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Graphiti » Code Generation for Graphiti
Code Generation for Graphiti [message #1073139] Wed, 24 July 2013 07:54 Go to next message
Till Fischer is currently offline Till Fischer
Messages: 57
Registered: August 2012
Member
Hi guys,

I just had a closer look a Graphiti and I really like it. I also tried working with GMF some time ago, but was not satisfied. The way code generation is implemented there imposes very high maintanance cost (which actually should be reduced by code generation...). And the architecture / API provided by Graphiti looks cleaner and more natural to me.

Nevertheless, there's a problem with Graphiti - which is some kind of a showstopper for me: One has to implement a large number of add/create/whatever features for all the model elements. This is rather tedious and IMHO a perfect candidate for code generation. I think combining the architecture and API of graphiti with the idea of "code generation" could lead to awesome results. Is anyone working on something like that? It has already been asked some time ago, and there has been some feedback, but no positive response. Is there something new about it?

I fear that some people might think that if Graphiti user-code is auto-generated, the result would be similar to what we already have with GMF. But I don't think that this is true. First of all, customizing the generated code for Graphiti would be easier because of the really good architecture/API, which would still be available, of course. Secondly, one could definitely avoid certain problems of GMF (just let me say "re-generation") by using double-derived classes (= "generation gap pattern" in the jargon of Java/Eclipse Smile).
Re: Code Generation for Graphiti [message #1073144 is a reply to message #1073139] Wed, 24 July 2013 08:07 Go to previous messageGo to next message
Till Fischer is currently offline Till Fischer
Messages: 57
Registered: August 2012
Member
Uhm... I already did some googling before writing my question... don't know how I could overlook this:

http://code.google.com/a/eclipselabs.org/p/spray/

but maybe there's something else... ?

[Updated on: Wed, 24 July 2013 08:10]

Report message to a moderator

Re: Code Generation for Graphiti [message #1073167 is a reply to message #1073144] Wed, 24 July 2013 08:55 Go to previous messageGo to next message
Andreas Graf is currently offline Andreas Graf
Messages: 151
Registered: July 2009
Senior Member
Hi,

here is how we do it at our project: http://5ise.quanxinquanyi.de/2011/08/18/a-dsl-for-graphiti-editors/

Regards,

Andreas
Re: Code Generation for Graphiti [message #1073301 is a reply to message #1073167] Wed, 24 July 2013 13:44 Go to previous message
Till Fischer is currently offline Till Fischer
Messages: 57
Registered: August 2012
Member
Andreas, thanks for the link. But you don't provide any source code / tooling that could be used directly, do you?

Regarding Spray: I just tried it out and it is amazing. Before asking whether anyone does code generation for Graphiti this morning, I was thinking how it could/should be provided to the user. Spray perfectly meets my imagination.

But the name ("Spray") is not ideal. I first missed it completely, because googling "code generation graphiti" shows "spray - A quick way of creating Graphiti" or even "Spraying - a quick way to create Graphitis". This simply couldn't be what I was looking for! Very Happy
Previous Topic:Feasibility question: UML Sequence Diagram Editor
Next Topic:"Click through" an unfilled RoundedRectangle
Goto Forum:
  


Current Time: Mon Sep 22 04:20:41 GMT 2014

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

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