Skip to main content



      Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » [EMF Forms] View Proxy on feature-level
[EMF Forms] View Proxy on feature-level [message #1792865] Wed, 25 July 2018 04:56 Go to next message
Eclipse UserFriend
Hi,

I have just looked into the view proxies (and hopefully understood them right)

Is there a way to reuse a view on a feature level?
Assuming I have a type "Comments" contained as a feature in multiple classes. Is there a way to define a e.g. Table for Comments, and reuse them in other views to display the comments feature?

I interpreted it as a feature-level proxy, similar to detailed editing in table, there you can define the details screen.
(maybe this came around in newer versions, I am still at 1.15)

Thanks,
Nikola
Re: [EMF Forms] View Proxy on feature-level [message #1792951 is a reply to message #1792865] Thu, 26 July 2018 08:04 Go to previous messageGo to next message
Eclipse UserFriend
Hi Nikola,

the ViewProxy is kind of feature bound.
Using the ViewProxy you can embed a predefined View.
As the ViewProxy does not have a DomainModelReference all the classes you want to use the ViewProxy must be SubClasses (in en EMF understanding) of the Class for which you create the ViewProxy.

Eg if you create an interface 'Addressable' with street and city as fields you could define a View for this and reuse this view in all view models for classes which implement this interface, eg a Person.

Cheers,
Eugen
Re: [EMF Forms] View Proxy on feature-level [message #1792960 is a reply to message #1792951] Thu, 26 July 2018 10:36 Go to previous message
Eclipse UserFriend
Hi Eugen,

good tip! Interfaces didn't cross my mind.

Unfortuanately, I am bound by a schema from which I am generating the model. I couldn't find anything regarding definition of interfaces in XSD here : https://www.eclipse.org/modeling/emf/docs/overviews/XMLSchemaToEcoreMapping.pdf
Will have to check the EMF Bible.

Anyhow, thank you very much for the great advice, I will keep it in mind for the future!


Cheers
Nikola

P.S.
Here is some information about defining interfaces in XSD:
https://www.eclipse.org/forums/index.php/t/133169/

[Updated on: Thu, 26 July 2018 11:11] by Moderator

Previous Topic:[Emf Forms] Tooltips in Views
Next Topic:Ecore to EMF Editor Plugin - Error in serialization
Goto Forum:
  


Current Time: Sat Jun 21 16:00:01 EDT 2025

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

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

Back to the top