|Example implementation of ECPModelElementOpener [message #1776925]
||Wed, 22 November 2017 20:12
| Jon Dæhlen
Registered: November 2017
Fellow Eclipse fans,|
If TLDR then Goto **
I am working on a ECP application which will handle several different data model types (described by EMF), which will require different editors to be opened. After fiddling around trying to tie the different editors to respective model types using "conventional e4 RCP" , I found the ECP platform which gave the desired functionality straight out of the box.
However, many of the attributes and references in the models requires custom controls for viewing and editing. This is described in "Replacing the default editor" and "Customize Editor Control" on the ECP home page https://www.eclipse.org/ecp/documentation.html.
As I several editors already are implemented (as Parts, using @PostContruct), I went for replacing the default editor. I made an implementation of the ECPModelElementOpener, which is executed in place of the default editor. But I am confused about how to build up the new part, as there is no composite or part given as argument to the overridden openModelElement() method. I tried to inject the EPartService, but it is not initialised by the framework (stays null).
So my question is:
**Can someone please provide a (simple) example implementation of the ECPModelElementOpener, which demonstrates the GUI build up and databinding towards the EMF?
Answers much appreciated.
Best regards from Norway,
Powered by FUDForum
. Page generated in 0.02011 seconds