Core
ResourceBundle
Class Hierarchy:

Provides locale-specific resources for multiple localizations. A default resource map and locale-specific resource maps may be added to a resource bundle. The resource bundle may then be queried to return a complete resource map for a specific locale. When a locale-specific map is requested, any entries not available specifically in that map will be provided by more generic resource maps that have been added to the bundle.

Constructor Summary
Public Core.ResourceBundle()
Creates a new ResourceBundle.

Class Method Summary
Public getParentLanguageCode()
Generates a less specific version of the specified language code.

Instance Method Summary
Public get()
Returns a locale-specific resource map.
Public set()
Adds a new locale-specific map to the bundle.
Public toString()

Constructor Detail
Core.ResourceBundle()
Creates a new ResourceBundle.
Parameters:
defaultMap - the default resource map

Class Method Detail
getParentLanguageCode
Generates a less specific version of the specified language code. Returns null if no "parent" language code can be determined. This operation is implemented by removing the sub-tag (if found) from the specified RFC 1766 language code. If the language code does not have a sub-tag, null is returned.
Parameters:
languageCode (String) - an RFC 1766 language code
Returns:
(String) a less specific version of the specified language code, or null if none can be determined

Instance Method Detail
get
Returns a locale-specific resource map. The returned map will contain entries from less-specific and/or the default map if they are not available from the map for the specified language code.
Parameters:
languageCode (String) - an RFC 1766 language code, or null to return the default map
Returns:
a locale-specific map for the language code

set
Adds a new locale-specific map to the bundle.
Parameters:
languageCode - the language code
map - the key-value resource map for the language code

toString