Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » @Preference(value="data") as value for other Annotation
@Preference(value="data") as value for other Annotation [message #800116] Thu, 16 February 2012 18:07 Go to next message
Filipp A. is currently offline Filipp A.
Messages: 49
Registered: February 2010
Member
Is it possible on some way to get value from preferences and put it as value for an other annotations ?
something like this -
@Inject
	@GeminiPersistenceUnit(unitName="puTest", properties = {
			@GeminiPersistenceProperty(name=PersistenceUnitProperties.JDBC_URL, valuePref=@Preference(value="jdbc_url"))
	})
	EntityManagerFactory emf;

Re: @Preference(value="data") as value for other Annotation [message #800243 is a reply to message #800116] Thu, 16 February 2012 21:16 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas Schindl
Messages: 5331
Registered: July 2009
Senior Member
No - i don't think that can work.

Tom

Am 16.02.12 19:07, schrieb Filipp A.:
> Is it possible on some way to get value from preferences and put it as
> value for an other annotations ?
> something like this -
> @Inject
> @GeminiPersistenceUnit(unitName="puTest", properties = {
>
> @GeminiPersistenceProperty(name=PersistenceUnitProperties.JDBC_URL,
> valuePref=@Preference(value="jdbc_url"))
> })
> EntityManagerFactory emf;
>
>
Re: @Preference(value="data") as value for other Annotation [message #800244 is a reply to message #800243] Thu, 16 February 2012 21:23 Go to previous message
Filipp A. is currently offline Filipp A.
Messages: 49
Registered: February 2010
Member
ok, can i use from my DS
DIEActivator.getDefault().getPreferencesService().getString(getNodePath(nodePath, requestingObject), key , null, null);
?
Previous Topic:e4 DI, Gemini & Persistence
Next Topic:Bug in org.eclipse.e4.core.di?
Goto Forum:
  


Current Time: Tue Sep 23 06:27:18 GMT 2014

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

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