What is the ResourceBundle class?
A ResourceBundle is a group of related sub classes sharing the same base name. For example, ButtonLabel is the base name. All the characters following the base name indicate the following elements respectively.
language code, country code, platform code.
Example : Locale.ButtonLabel_en_GB_Unix - It matches the Locale specifies the code for English language(en) and the country code for Great Britain(GB) and the UNIX platform.
What is the ResourceBundle class?
- ResourceBundle contains locale-specific objects.
- A program can load locale-specific objects from the resource bundle per the current user's locale.
- This makes the program free of the locale specific clutter and the programmer can focus on logic.
ResourceBundle allows programs to:1. Be easily localized, or translated, into different languages
2. Be easily modified later to support even more locales
3. Handle multiple locales simultaneously