Package com.ibm.icu.impl
Class ResourceBundleWrapper
java.lang.Object
java.util.ResourceBundle
com.ibm.icu.util.UResourceBundle
com.ibm.icu.impl.ResourceBundleWrapper
just a wrapper for Java ListResourceBundles and
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class
Loader for bundle instances, for caching.Nested classes/interfaces inherited from class java.util.ResourceBundle
ResourceBundle.Control
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate String
private ResourceBundle
private static CacheBase
<String, ResourceBundleWrapper, ResourceBundleWrapper.Loader> private static final boolean
private String
Fields inherited from class com.ibm.icu.util.UResourceBundle
ARRAY, BINARY, INT, INT_VECTOR, NONE, STRING, TABLE
Fields inherited from class java.util.ResourceBundle
parent
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String
Returns the base name of the resource bundlestatic ResourceBundleWrapper
getBundleInstance
(String baseName, String localeID, ClassLoader root, boolean disableFallback) getKeys()
Returns the keys in this bundle as an enumerationprotected String
Returns the localeIDReturns the parent bundleReturns the RFC 3066 conformant locale id of this resource bundle.protected Object
handleGetObject
(String aKey) private void
private static ResourceBundleWrapper
instantiateBundle
(String baseName, String localeID, String defaultID, ClassLoader root, boolean disableFallback) private static boolean
localeIDStartsWithLangSubtag
(String localeID, String lang) Methods inherited from class com.ibm.icu.util.UResourceBundle
findTopLevel, findTopLevel, get, get, getBinary, getBinary, getBundleInstance, getBundleInstance, getBundleInstance, getBundleInstance, getBundleInstance, getBundleInstance, getBundleInstance, getBundleInstance, getInt, getIntVector, getIterator, getKey, getLocale, getSize, getString, getString, getStringArray, getType, getUInt, getVersion, handleGet, handleGet, handleGetKeys, handleGetStringArray, handleKeySet, instantiateBundle, isTopLevelResource, keySet
Methods inherited from class java.util.ResourceBundle
clearCache, clearCache, containsKey, getBaseBundleName, getBundle, getBundle, getBundle, getBundle, getBundle, getBundle, getBundle, getBundle, getObject, getString, getStringArray, setParent
-
Field Details
-
bundle
-
localeID
-
baseName
-
keys
-
BUNDLE_CACHE
-
DEBUG
private static final boolean DEBUG
-
-
Constructor Details
-
ResourceBundleWrapper
-
-
Method Details
-
handleGetObject
Description copied from class:UResourceBundle
- Overrides:
handleGetObject
in classUResourceBundle
-
getKeys
Description copied from class:UResourceBundle
Returns the keys in this bundle as an enumeration- Overrides:
getKeys
in classUResourceBundle
- Returns:
- an enumeration containing key strings, which is empty if this is not a bundle or a table resource
-
initKeysVector
private void initKeysVector() -
getLocaleID
Description copied from class:UResourceBundle
Returns the localeID- Specified by:
getLocaleID
in classUResourceBundle
- Returns:
- The string representation of the localeID
-
getBaseName
Description copied from class:UResourceBundle
Returns the base name of the resource bundle- Specified by:
getBaseName
in classUResourceBundle
- Returns:
- The string representation of the base name
-
getULocale
Description copied from class:UResourceBundle
Returns the RFC 3066 conformant locale id of this resource bundle. This method can be used after a call to getBundleInstance() to determine whether the resource bundle returned really corresponds to the requested locale or is a fallback.- Specified by:
getULocale
in classUResourceBundle
- Returns:
- the locale of this resource bundle
-
getParent
Description copied from class:UResourceBundle
Returns the parent bundle- Specified by:
getParent
in classUResourceBundle
- Returns:
- The parent bundle
-
getBundleInstance
public static ResourceBundleWrapper getBundleInstance(String baseName, String localeID, ClassLoader root, boolean disableFallback) -
localeIDStartsWithLangSubtag
-
instantiateBundle
private static ResourceBundleWrapper instantiateBundle(String baseName, String localeID, String defaultID, ClassLoader root, boolean disableFallback)
-