Accessing language preferences [message #1062984] |
Tue, 11 June 2013 11:26  |
Eclipse User |
|
|
|
I set up my language preferences page in my UI project, and can access them inside the UI packages like this:
IPreferenceStore store = DSLActivator.getInstance().getPreferenceStore();
String data = store.getString("whatever");
Now, I want to access it from the main Xtext project (i.e., the one with the grammar, validator, etc.). However, my DSLActivator is inside an internal UI package. I could export it, but it seems it was not supposed to be. How else can I access preferences?
|
|
|
|
|
|
|
|
|
Re: Accessing language preferences [message #1322044 is a reply to message #1321693] |
Tue, 29 April 2014 13:01  |
Eclipse User |
|
|
|
Hi,
I'm no longer convinced that the question was a good one.
In standalone setups, the data shouldn't even be pulled from some Eclipse configuration storage, but rather depend on the environment.
For invocations via xtext-maven-plugin, for example, the <configuration> section of the pom.xml should provide the values. Not sure if such functionality is already supported.
For now, I'll go and do an easy fallback, and provide configuration from environment or system properties.
Best regards,
Michael
|
|
|
Powered by
FUDForum. Page generated in 0.25651 seconds