[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.modeling.gmf] Re: Problems with the Mapping model

Maybe we are giving some redundant information now, but we would like to explain again what our class diagram looks like.
We are making an editor for UML Statemachines and our ecore diagram looks like this:


http://farm4.static.flickr.com/3075/3113506390_bfe95dd614_o.jpg

We have read through the whole thread and realized that that there was some things that we continued to ask that you had already explained. But, there is still some things that we donŽt understand (surprise :-) )


Sure. One solution as I already tald you in this thread is to create
_only_one_
link so there will be only one if() statement in generated
???VisualIdRegistry.

-----------
We guess that you mean create only one link mapping. For example we can create one like this:
<Transition{Transition.sources:State->Transition.targets:State}/Transition>


But then how do we get ONE link mapping to connect to the three kinds of nodes. If it is somewhere in the gmfmap, please specify where.

--------
Another solution (except modifying this code by hands) is to create
additional
constraints in .gmfmap model to distinguish between these different types of the links. Like (domain specialization element below LinkMapping):
self.source.oclIsKindOf(A)

We have never written any ocl and donŽt really understand how to write the constraints in it. We have looked at your example but we still donŽt understand how we should do it. (We added link constraints in the mapping model to the link Mapping and wrote some code snippets in the body part that didnŽt work.)Is there a way to set this in Java instead :-)


This is the first time we use GMF or any kind of framework in Eclipse by the way and we understand that we ask a lot of stupid questions. Sorry about that....