Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Two graphical views of the same metamodel element
Two graphical views of the same metamodel element [message #172629] Fri, 15 February 2008 13:47 Go to next message
Eclipse UserFriend
Originally posted by: ismar.slomic.gmail.com

Hi,
I am working on a service modelling GMF editor.

As you can see in this screenshot (http://www.slomic.no/upms-light.gif ) the
interfaces (which contains attributes and operations) is represented as
ellipses in this diagram. Now, I want to create a new view of the interface
details, where you can add operations and attributes (properties). Like if
you double click on the interface ellipse you get another graphical
representation of the very same interface, in new empty view. The interface
is now represented as class (rectangle), where you have attribute and
operation compartments. Is this very difficult to manage in GMF? Could you
maybe send me existing code on a feature like this, and tell in words how I
should proceed to solve this.

Thanks, in advance!

Regards Ismar
Re: Two graphical views of the same metamodel element [message #172637 is a reply to message #172629] Fri, 15 February 2008 13:57 Go to previous messageGo to next message
Alexander Shatalin is currently offline Alexander ShatalinFriend
Messages: 2928
Registered: July 2009
Senior Member
Hello Ismar,

Looks like similar question was recently discussed here: http://dev.eclipse.org/newslists/news.eclipse.modeling.gmf/m sg10919.html

-----------------
Alex Shatalin
Re: Two graphical views of the same metamodel element [message #172659 is a reply to message #172637] Fri, 15 February 2008 15:16 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: ismar.slomic.gmail.com

Hi Alex,
thank you for the link, but I didn
Re: Two graphical views of the same metamodel element [message #172666 is a reply to message #172659] Fri, 15 February 2008 15:19 Go to previous messageGo to next message
Alexander Shatalin is currently offline Alexander ShatalinFriend
Messages: 2928
Registered: July 2009
Senior Member
Hello Ismar,

Some additional information you can find here: http://wiki.eclipse.org/Diagram_Partitioning
In general you don't need to write any code - you have to generate two GMF
diagrams for top-level and child elements and then bind them together to
open second diagram by double-clicking on first one.

-----------------
Alex Shatalin
Re: Two graphical views of the same metamodel element [message #172673 is a reply to message #172666] Fri, 15 February 2008 16:02 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: ismar.slomic.gmail.com

Thank you very much Alex! This was exactly what I was looking for, and the
Cheat Sheet in Eclipse did the process much easier to follow.

Have a nice weekend :)

Regards Ismar


"Alex Shatalin" <vano@borland.com> wrote in message
news:3c3172e61e0bf8ca3e05ba004d1d@news.eclipse.org...
> Hello Ismar,
>
> Some additional information you can find here:
> http://wiki.eclipse.org/Diagram_Partitioning
> In general you don't need to write any code - you have to generate two GMF
> diagrams for top-level and child elements and then bind them together to
> open second diagram by double-clicking on first one.
>
> -----------------
> Alex Shatalin
>
>
Re: Two graphical views of the same metamodel element [message #173080 is a reply to message #172666] Wed, 20 February 2008 10:18 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: Stefan.Warwas.dfki.de

Hello Alex

I have a question regarding the "Diagram Partitioning" guide you
mentioned: Is step 6 of usecase 2 obligated? I never duplicated the
genmodel and changed the "model name" attribute and it works fine. Why
do I have to do this? Isn't it sufficient to change the "package name
prefix" of the sub-diagram?

Regards,

Stefan

Alex Shatalin wrote:
> Hello Ismar,
>
> Some additional information you can find here:
> http://wiki.eclipse.org/Diagram_Partitioning
> In general you don't need to write any code - you have to generate two
> GMF diagrams for top-level and child elements and then bind them
> together to open second diagram by double-clicking on first one.
>
> -----------------
> Alex Shatalin
>
>
Re: Two graphical views of the same metamodel element [message #173096 is a reply to message #173080] Wed, 20 February 2008 11:35 Go to previous messageGo to next message
Alexander Shatalin is currently offline Alexander ShatalinFriend
Messages: 2928
Registered: July 2009
Senior Member
Hello Stefan,

To be honest, I'm not an author of this guide, so I do not know why this
"hacky" part was introduced - to my understanding there should be no "hacking"
in DiagramPartitioning. ;-) In any case, answering your question if you are
working with two or more diagrams based on the same meta-model (.ecore file)
then you should take care on uniqueness of some .gmfgen model properties.
All tese properties are mentioned as "unique" in this document: http://wiki.eclipse.org/GMF_GenModel_Hints.
Just search for "unique" string there and read corresponding description.

I can admit your diagrams are working properly even without these properties
set correctly, but in future you can face some problems with this (on future
diagram modification + regeneration). So i suggest to modify corresponding
properties. Hope I answered your question.

-----------------
Alex Shatalin
Re: Two graphical views of the same metamodel element [message #173119 is a reply to message #173096] Wed, 20 February 2008 11:53 Go to previous message
Eclipse UserFriend
Originally posted by: Stefan.Warwas.dfki.de

Hello Alex

I am aware of these unique properties. I was just wondering about this
"hacky" part. Thanks!

Regards,

Stefan

Alex Shatalin wrote:
> Hello Stefan,
>
> To be honest, I'm not an author of this guide, so I do not know why this
> "hacky" part was introduced - to my understanding there should be no
> "hacking" in DiagramPartitioning. ;-) In any case, answering your
> question if you are working with two or more diagrams based on the same
> meta-model (.ecore file) then you should take care on uniqueness of some
> .gmfgen model properties. All tese properties are mentioned as "unique"
> in this document: http://wiki.eclipse.org/GMF_GenModel_Hints. Just
> search for "unique" string there and read corresponding description.
> I can admit your diagrams are working properly even without these
> properties set correctly, but in future you can face some problems with
> this (on future diagram modification + regeneration). So i suggest to
> modify corresponding properties. Hope I answered your question.
>
> -----------------
> Alex Shatalin
>
>
Previous Topic:Location and Set commands
Next Topic:Custom deletion behaviour
Goto Forum:
  


Current Time: Thu Apr 25 07:31:33 GMT 2024

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

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

Back to the top