FileDocCategorySizeDatePackage
ResourceManagerFactory.javaAPI DocphoneME MR2 API (J2ME)4535Wed May 02 18:00:46 BST 2007com.sun.j2me.global

ResourceManagerFactory

public abstract class ResourceManagerFactory extends Object
This class represents a factory for creating resource managers.

Fields Summary
protected static final String
GLOBAL_PREFIX
Every application resource file is under global directory.
protected static final String
RESOURCE_FILE_EXTENSION
Resource file extension constant.
Constructors Summary
public ResourceManagerFactory()
Creates a new instance of ResourceManagerFactory.



                
       
Methods Summary
public abstract ResourceManagergetManager(java.lang.String baseName)
Returns an instance of ResourceManager class for the given base name and system's default locale.

param
baseName the base name
return
the resource manager for the base name
throws
ResourceException if the resources for the base name doesn't exist
throws
UnsupportedLocaleException if the resources of the specified base name aren't available for the system's default locale
see
javax.microedition.global.ResourceManager#getManager(String)

public abstract ResourceManagergetManager(java.lang.String baseName, java.lang.String locale)
Creates an instance of ResourceManager class for the given base name and locale.

param
baseName the base name
param
locale the locale
return
the resource manager for the base name and locale
throws
ResourceException if the resources for the base name and locale doesn't exist
throws
UnsupportedLocaleException if the resources of the specified base name aren't available for the locale
see
javax.microedition.global.ResourceManager#getManager(String, String)

public abstract ResourceManagergetManager(java.lang.String baseName, java.lang.String[] locales)
Creates an instance of ResourceManager class for the given base name and the first matching locale in the supplied array.

param
baseName the base name
param
locales the array of locale
return
the resource manager for the base name and the matched locale
throws
ResourceException if no resources for the base name and any of the locales in the array are found
throws
UnsupportedLocaleException if the resources of the specified base name are available for no locale from the array
see
javax.microedition.global.ResourceManager#getManager(String, String[])

public abstract java.lang.String[]getSupportedLocales(java.lang.String baseName)
Returns a list of locales supported by the given baseName. A resource manager can be constructed for each locale from the list and the base name.

param
baseName the base name
return
the list of the supported locales