Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » [EMF Forms] Using ViewModelService together with E4 DI
[EMF Forms] Using ViewModelService together with E4 DI [message #1251784] Thu, 20 February 2014 15:48 Go to next message
Paweł Doleciński is currently offline Paweł DolecińskiFriend
Messages: 44
Registered: January 2014
Member
Hi,

I've started using EMF Forms from the latest RC release of ECP 1.2.x.

Now, when I've got embedded editor I need to implement my own ViewLocaleService and ReferenceService.

I'd like to somehow use dependency injection from E4 there or at least have access to IEclipseContext.

So far, all services are registered using rg.eclipse.emf.ecp.view.context.viewServices
extension point, so I do not have any access to this fancy feature.

One possible solution would be to use custom ViewModelContextFactory with extended ViewModelContextImpl, but this one is internal and has only internal export (thanks for this package export anyway).

Better solution would be to add possibility to add custom things to ViewModelContext or easier extending.

Maybe I overlooked something.
Any ideas?

Cheers,
Paweł.
Re: [EMF Forms] Using ViewModelService together with E4 DI [message #1252101 is a reply to message #1251784] Thu, 20 February 2014 23:32 Go to previous messageGo to next message
Jonas Helming is currently offline Jonas HelmingFriend
Messages: 699
Registered: July 2009
Senior Member
Hi,

the general issue is, that we are single sourcing between 3.x and e4, so
any change, which makes us incompatible with 3.x is currently a no-go.
However, I would need to think about ways to make DI available, could
you file a BR for this?

Regards

Jonas

Am 20.02.2014 16:48, schrieb Paweł Doleciński:
> Hi,
>
> I've started using EMF Forms from the latest RC release of ECP 1.2.x.
>
> Now, when I've got embedded editor I need to implement my own
> ViewLocaleService and ReferenceService.
> I'd like to somehow use dependency injection from E4 there or at least
> have access to IEclipseContext.
>
> So far, all services are registered using
> rg.eclipse.emf.ecp.view.context.viewServices
> extension point, so I do not have any access to this fancy feature.
>
> One possible solution would be to use custom ViewModelContextFactory
> with extended ViewModelContextImpl, but this one is internal and has
> only internal export (thanks for this package export anyway).
>
> Better solution would be to add possibility to add custom things to
> ViewModelContext or easier extending.
>
> Maybe I overlooked something.
> Any ideas?
>
> Cheers,
> Paweł.
Re: [EMF Forms] Using ViewModelService together with E4 DI [message #1252480 is a reply to message #1252101] Fri, 21 February 2014 09:02 Go to previous message
Paweł Doleciński is currently offline Paweł DolecińskiFriend
Messages: 44
Registered: January 2014
Member
Hi,

I am aware about this compatibility issue. That's way I was thinking about having possibility to add eclipse context to the view context when it's needed without giving strict dependency. This would additionally allow to add any other custom things.
Because I thing it is not necessary to have DI (would be nice), but only flexibility on retrieving something from EclipseContext programmatically.

Here is BR: 428711
Previous Topic:ECP/ EMF Forms , wordwrap in text widgets
Next Topic:[EMFClient] How to enable the new e4 views (ECP 1.2) in my own application
Goto Forum:
  


Current Time: Fri Apr 26 22:17:28 GMT 2024

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

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

Back to the top