Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Restrict properties in diagram editor.
Restrict properties in diagram editor. [message #221472] Sun, 15 March 2009 21:55 Go to next message
Achilleas is currently offline AchilleasFriend
Messages: 88
Registered: July 2009
Member
Hi all,

I have produced two GMF diagram editors that are based onto the same Ecore
metamodel definition.

The first GMF diagram editor allows to define models that are selected (1
or more of them) accordingly by the user and loaded as required when a new
model is created with the second GMF editor. Therefore the second GMF
editor opens up with the existing model instance loaded directly from the
xmi specific files.

I would like to know if there is a way to restrict the changes that can be
made to the loaded model instances. For instance assign some properties to
be read-only when loaded, or take specific values. This could be achieved
for example if I assign something like enumerations to those properties in
the first GMF editor?

The bottom line is to use the models defined in the first editor as
templates in the second editor and extend the model definition accordingly.

I hope it is clear what i am trying to achieve. PLease if you have any
suggestions on how to achieve this are more than welcome.

Thanks,

Achilleas
Re: Restrict properties in diagram editor. [message #221525 is a reply to message #221472] Mon, 16 March 2009 12:07 Go to previous messageGo to next message
Achilleas is currently offline AchilleasFriend
Messages: 88
Registered: July 2009
Member
Hi again,

Does anyone has any suggestions on this?

Thanks,

Achilleas
Re: Restrict properties in diagram editor. [message #221655 is a reply to message #221472] Tue, 17 March 2009 12:32 Go to previous message
Achilleas is currently offline AchilleasFriend
Messages: 88
Registered: July 2009
Member
Hi,

I am short of solutions on this aspect. Let me repeat on what I am trying
to achieve.

I have two GMF editors based on the same metamodel. I use the first GMF
editor to define parts of a larger model that are saved into individual
resources; which I consider as templates. Then I have extended the wizard
so I can preload these templates, when the new model is initialised in the
second GMF editor.

Therefore the second GMF editor allows to use those templates and add
additional elements to construct the final model. What I want to know is
if I can declare the values of the template elements to be read-only or
have a fixed range of values when these are loaded in the second GMF
editor.

I hope I could explain properly what I am trying to achieve. Any ideas
will be greatly appreciated.

Thanks,

Achilleas
Previous Topic:How to implement content assist for texts in GMF?
Next Topic:Saving additional resources
Goto Forum:
  


Current Time: Fri Apr 19 23:46:54 GMT 2024

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

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

Back to the top