public final class ResourceManager
Manages resource data. Resource data can be stored and retrieved in a locale- specific manner. This enables the creation of localizable applications.
Fields
Name | Description |
---|---|
EXTENSION | Extension given to all resource files. |
Constructors
Name | Description |
---|---|
ResourceManager(IResourceLoader loader, String baseName) | Creates a ResourceManager. |
Methods
Name | Description |
---|---|
flush() | Releases any cached resource data. |
getBoolean(String name) | Retrieves a boolean for the specified property that is valid for the current locale. |
getBoolean(Locale locale, String name) | Retrieves the boolean for the specified property that is valid for the specified locale. |
getByte(String name) | Retrieves a byte for the specified property that is valid for the current locale. |
getByte(Locale locale, String name) | Retrieves the byte for the specified property that is valid for the specified locale. |
getChar(String name) | Retrieves a character for the specified property that is valid for the current locale. |
getChar(Locale locale, String name) | Retrieves the character for the specified property that is valid for the specified locale. |
getDouble(String name) | Retrieves a double for the specified property that is valid for the current locale. |
getDouble(Locale locale, String name) | Retrieves the double for the specified property that is valid for the specified locale. |
getFloat(String name) | Retrieves a float for the specified property that is valid for the current locale. |
getFloat(Locale locale, String name) | Retrieves the float for the specified property that is valid for the specified locale. |
getInt(String name) | Retrieves a integer for the specified property that is valid for the current locale. |
getInt(Locale locale, String name) | Retrieves the integer for the specified property that is valid for the specified locale. |
getLocaleFileName(Locale locale) | Retrieves the file name for the specified locale. |
getLocaleFileNameFromBase(Locale locale, String baseName) | Computes the localized file name given the specified locale and baseName. |
getLong(String name) | Retrieves a long for the specified property that is valid for the current locale. |
getLong(Locale locale, String name) | Retrieves the long for the specified property that is valid for the specified locale. |
getNames() | Retrieves all the property names for the current locale. |
getNames(Locale locale) | Retrieves all the property names for the specified locale. |
getObject(String name) | Retrieves an object for the specified property that is valid for the current locale. |
getObject(Locale locale, String name) | Retrieves the object for the specified property that is valid for the specified locale. |
getObjects() | Retrieves all the property values for the current locale. |
getObjects(Locale locale) | Retrieves all the property values for the current locale. |
getShort(String name) | Retrieves a short for the specified property that is valid for the current locale. |
getShort(Locale locale, String name) | Retrieves the short for the specified property that is valid for the specified locale. |
getString(String name) | Retrieves a string for the specified property that is valid for the current locale. |
getString(Locale locale, String name) | Retrieves the string for the specified property that is valid for the specified locale. |
getValidData(Object value) | Retrieves true if the specified value can be stored as a resource property. |
loadResourceAsStream(Class src, String name) | Loads an arbitrary binary resource file for the specified class. |
setBoolean(Locale locale, String name, boolean value) | Sets the value for a property for the specified locale. |
setByte(Locale locale, String name, byte value) | Sets the value for a property for the specified locale. |
setChar(Locale locale, String name, char value) | Sets the value for a property for the specified locale. |
setDouble(Locale locale, String name, double value) | Sets the value for a property for the specified locale. |
setFloat(Locale locale, String name, float value) | Sets the value for a property for the specified locale. |
setInt(Locale locale, String name, int value) | Sets the value for a property for the specified locale. |
setLong(Locale locale, String name, long value) | Sets the value for a property for the specified locale. |
setObject(Locale locale, String name, Object value) | Sets the value for a property for the specified locale. |
setShort(Locale locale, String name, short value) | Sets the value for a property for the specified locale. |
setString(Locale locale, String name, String value) | Sets the value for a property for the specified locale. |
Creates a ResourceManager. The resource manager gets data relative to the specified component that has the baseName specified. The baseName should be the root name of the resource files. For example, the base name for the files "MyResource_enu.resources" and "MyResource_jpn.resources" is "MyResource".
Releases any cached resource data.
Returns the property value.
Retrieves a boolean for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the boolean for the specified property that is valid for the specified locale.
Returns the property value.
Retrieves a byte for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the byte for the specified property that is valid for the specified locale.
Returns the property value.
Retrieves a character for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the character for the specified property that is valid for the specified locale.
Returns the property value.
Retrieves a double for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the double for the specified property that is valid for the specified locale.
Returns the property value.
Retrieves a float for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the float for the specified property that is valid for the specified locale.
Returns the property value.
Retrieves a integer for the specified property that is valid for the current locale.
Returns property value.
Retrieves the integer for the specified property that is valid for the specified locale.
Returns the localized file name.
Retrieves the file name for the specified locale.
Returns the localized file name.
Computes the localized file name given the specified locale and baseName.
Returns the property value.
Retrieves a long for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the long for the specified property that is valid for the specified locale.
Returns a string array containing all the names for properties.
Retrieves all the property names for the current locale.
Returns a string array containing all the names for properties.
Retrieves all the property names for the specified locale.
Returns the property value.
Retrieves an object for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the object for the specified property that is valid for the specified locale.
Returns an object array containing all the values for properties.
Retrieves all the property values for the current locale.
Returns an object array containing all the values for properties.
Retrieves all the property values for the current locale.
Returns the property value.
Retrieves a short for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the short for the specified property that is valid for the specified locale.
Returns the property value.
Retrieves a string for the specified property that is valid for the current locale.
Returns the property value.
Retrieves the string for the specified property that is valid for the specified locale.
Returns true if the value can be stored in a resource file.
Retrieves true if the specified value can be stored as a resource property.
Returns the IDataStream for the specified resource.
Loads an arbitrary binary resource file for the specified class. This does not load a resource property file. It is a standalone binary file that is a resource for the specified class.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.
Sets the value for a property for the specified locale.