Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 79232 - Need to know if -nl parameter was set
Summary: Need to know if -nl parameter was set
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Runtime (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: 3.1 M4   Edit
Assignee: Pascal Rapicault CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 78013
  Show dependency tree
 
Reported: 2004-11-22 14:50 EST by Tod Creasey CLA
Modified: 2004-12-07 16:51 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tod Creasey CLA 2004-11-22 14:50:38 EST
We need to be able to determine if the user set thier locale using the -nl 
command line parameter or if it was determined by querying the default Locale.

I am happy with a system property (e.g. "osgi.nl.user") if you want to do it 
that way so as not to change any current behaviour.
Comment 1 Pascal Rapicault CLA 2004-11-22 15:06:29 EST
Given the nature of the initial problem that we are trying to fix, a very low 
disturbance fix has been implemented.

The osgi.nl.user is set to the osgi.nl value if one of -nl or osgi.nl.user has 
been specified. The fix is made in EnvironmentInfo.java.
Comment 2 Jeff McAffer CLA 2004-11-22 22:01:51 EST
How does this handle the case where the user does -Dosgi.nl or puts it in their 
config.ini file (where I would expect an installer to write it)
Comment 3 Pascal Rapicault CLA 2004-11-23 09:22:13 EST
Every case is handled in the EnvironmentInfo#setupSystemContext().
Comment 4 Tod Creasey CLA 2004-12-07 16:17:54 EST
This API is not public.
Comment 5 Pascal Rapicault CLA 2004-12-07 16:23:14 EST
The code for the fix is in #setupSystemContext, but the fix itself consists in
setting the  osgi.nl.user property. See comment #1.
Comment 6 Tod Creasey CLA 2004-12-07 16:36:18 EST
So what public API can I use to get this value?
Comment 7 Pascal Rapicault CLA 2004-12-07 16:51:03 EST
java.lang.System.getProperty("osgi.nl.user")