www.HadoopExam.com

HadoopExam Learning Resources

HadoopExam Training, Interview Questions, Certifications, Projects, POC and Hands On exercise access

    40000+ Learners upgraded/switched career    Testimonials

Question 3: Assume that you've the following resource bundles in your classpath:

Question 3: Assume that you've the following resource bundles in your classpath:

ResourceBundle.properties

ResourceBundle_ar.properties

ResourceBundle_en.properties

ResourceBundle_it.properties

ResourceBundle_it_IT_Rome.properties

Also assume that the default locale is English (US), where the language code is en and

country code is US. Which one of these five bundles will be loaded for the call

loadResourceBundle("ResourceBundle", new Locale("fr", "CA", ""));?

1.        ResourceBundle.properties

2.        ResourceBundle_ar.properties

3.        ResourceBundle_en.properties

4.        ResourceBundle_it.properties

5.        ResourceBundle_it_IT_Rome.properties

Correct Answer : 3 Exp : Java looks for candidate locales for a base bundle named ResourceBundle and locale

French (Canada), and checks for the presence of the following property files:

ResourceBundle_fr_CA.properties

ResourceBundle_fr.properties

Since both of them are not there, Java searches for candidate locales for the base

bundle named ResourceBundle and a default locale (English - United States):

ResourceBundle_en_US.properties

ResourceBundle_en.properties

Java finds that there is a matching resource bundle,

ResourceBundle_en.properties. Hence it loads this resource bundle

I have cleared my Java 1Z0-808 Certification exam with 92% using this simulator

I have cleared my Java 1Z0-809 Certification exam with 96% using this simulator

Visit Home Page : http://hadoopexam.com for more detail . As you are not blacklisted user.

You are here: Home Oracle Java 1Z0-809 Question 3: Assume that you've the following resource bundles in your classpath: