|Re: Getting the Eclipse Context for DI [message #580885 is a reply to message #580851]
||Mon, 16 August 2010 20:59
| Thomas Schindl
Registered: July 2009
You can't. Who is creating the instance? In the end there always have to|
be something was instatiated by the e4 platform and you need to pass
through the IEclipseContext from there.
Am 16.08.10 22:22, schrieb U. Geerds:
> Hi anybody,
> I'm trying to use @Inject values with the
> ContextInjectionFactory.make(MyClass.class, context). To do this, i need
> the correct EclipseContext. If the class who calls
> ContextInjectionFactory.make or .inject, has a injected EclipseContext
> from the E4, it works fine.
> What is right way, to get the EclipseContext from a POJO who isn't
> created from the E4 and hasn't a injected Context and resides at another
> Plug-In? It is possible?
> I played around with the EclipseContextFactory, who is described at the
> vogella articles, but i get always a empty or invalid EclipseContext.
> Thanks a lot. Uwe
Powered by FUDForum
. Page generated in 0.03083 seconds