Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » [GMF Tooling] References container/child(Improve generating process)
[GMF Tooling] References container/child [message #731273] Fri, 30 September 2011 13:37 Go to next message
Arthur Daussy is currently offline Arthur DaussyFriend
Messages: 30
Registered: September 2011
Member
Hi everyone,

I'm currently working on MDT Papyrus which is a GMF generated editor.

For now we encounter some problem for regeneration one of our diagram.

The problem is the following:

We are working on the Activity diagram. In this diagram for most of the elements we can have several containers:

-> The Activity Diagram container

-> And all the Grouping element (example : Structured Activity node)

For now in the GenMap model the only container set is the Activity Diagram. If we add the other containers in the map, during generation a new element for each container will created. Or we want only one implementation of Structured Activity Node (for example) and not one for each element it can contain.

For now the solution is manually add into the GenModel each reference into the "container" and "child" attribute. However each time we regenerate the genModel we lose all those references. So we have to add them manually again and it is quite pain full.

So I'm writing here to know if:

-> There is any way to avoid when regenerating from GenMap to GenModel to override those manually added elements?

-> There is a way to reference existing element in container/child attribute to avoid creating new elements each time you add them.



Thanks for any help you can give me.
Re: [GMF Tooling] References container/child [message #731297 is a reply to message #731273] Fri, 30 September 2011 13:58 Go to previous messageGo to next message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 771
Registered: July 2009
Location: Grenoble, France
Senior Member
On 30/09/2011 15:37, Arthur Daussy wrote:
> Hi everyone,
>
> I'm currently working on MDT Papyrus which is a GMF generated editor.
> For now we encounter some problem for regeneration one of our diagram.
>
> The problem is the following:
>
> We are working on the Activity diagram. In this diagram for most of the
> elements we can have several containers:
>
> -> The Activity Diagram container
>
> -> And all the Grouping element (example : Structured Activity node)
>
> For now in the GenMap model the only container set is the Activity
> Diagram. If we add the other containers in the map, during generation a
> new element for each container will created. Or we want only one
> implementation of Structured Activity Node (for example) and not one for
> each element it can contain.
>
> For now the solution is manually add into the GenModel each reference
> into the "container" and "child" attribute. However each time we
> regenerate the genModel we lose all those references. So we have to add
> them manually again and it is quite pain full.
>
> So I'm writing here to know if:
>
> -> There is any way to avoid when regenerating from GenMap to GenModel
> to override those manually added elements?

GMFMap to GMFGen keeps manually modified stuff for some parts of the
models. However, it is not true for everything. You can open a bug
providing your GMF files and the scenario, and we'll see whether there
is a workaround or an easy fix possible.

> -> There is a way to reference existing element in container/child
> attribute to avoid creating new elements each time you add them.

In your gmfmap, you can use "referenced child" to reference a
NodeMapping instead of defining a new one.
However I think this does not change anything during generation. once
again, you should open a bug for that.

HTH
--
http://mickaelistria.wordpress.com
http://twitter.com/#!/mickaelistria
http://www.petalslink.com
Re: [GMF Tooling] References container/child [message #731316 is a reply to message #731297] Fri, 30 September 2011 15:56 Go to previous message
Arthur Daussy is currently offline Arthur DaussyFriend
Messages: 30
Registered: September 2011
Member
Thanks I going to open a bug with corresponding Models next week.

Thanks for your help.

Arthur Daussy
Previous Topic:ToolGroup stack problem
Next Topic:Sharing content within diagram
Goto Forum:
  


Current Time: Mon Dec 22 04:23:09 GMT 2014

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

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