This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes A Localization question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "A Localization question" Watch "A Localization question" New topic
Author

A Localization question

Zhixiong Pan
Ranch Hand

Joined: Jan 25, 2006
Posts: 239
Hi all,

Please help with below question regarding the localization. Thanks.

A sample program ships with 2 properties files - Base.properties, Base_fr.properties. If the current Locale, Locale.ENGLISH has no matching properties file, what will happen when the ResourceBundle.getBundle method is called with 'Base' and Locale. English as parameters?



A Since a matching properties file is not found, an exception is thrown

B This would not pose a problem because when a matching properties file is not found, the default properties file is used instead.


SCJP 1.4 SCJD
Luciano A. Pozzo
Ranch Hand

Joined: Jun 20, 2005
Posts: 112
"B" is correct. If the matching properties file is not found, the default is used instead.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: A Localization question
 
Similar Threads
is it possible to change jvm locale by using command line parameters ?
SCEA Question about ResourceBundle: What is your answer?
Warnings with message resource
Need Help regarding Internationalization in JSF
[Wicket] Localization of page layout