com.ibm.commerce.tools.util
Class ResourceDirectory
java.lang.Object
com.ibm.commerce.tools.util.ResourceDirectory
- public class ResourceDirectory
- extends java.lang.Object
Maintains the set of all registered bean instantiators.
Method Summary |
static void |
initializeInstDirectory()
Loads all resources defined by the resources.xml files. |
static void |
loadInstDirectory(java.util.Vector model_files)
Populates the instantiator directory from the given XML based configuration file. |
static java.lang.Object |
lookup(java.lang.String key)
Gets the resource from the cache. |
static java.lang.Object |
lookup(java.lang.String key, java.util.Locale locale)
Gets the resource from the cache. |
static java.lang.Object |
lookup(java.lang.String name_space, java.lang.String inst_name)
Gets the resource from the cache. |
static java.lang.Object |
lookup(java.lang.String name_space, java.lang.String inst_name, java.util.Locale locale)
Gets the resource from the cache. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
initializeInstDirectory
public static final void initializeInstDirectory()
throws ECSystemException
- Loads all resources defined by the resources.xml files. Each XML file may include additional files which must then also be loaded. Each resource is stored in the namespace defined in the XML file.
-
- Throws:
- ECSystemException - If an error occurs, an exception is thrown.
loadInstDirectory
public static final void loadInstDirectory(java.util.Vector model_files)
throws ECSystemException
- Populates the instantiator directory from the given XML based configuration file.
-
- Parameters:
- model_files - the XML configuration file
- Throws:
- ECSystemException - If an error occurs, an exception is thrown.
lookup
public static final java.lang.Object lookup(java.lang.String key)
throws ECSystemException
- Gets the resource from the cache. If no locale has been specified, the default server locale is used if the resource is locale-dependant.
-
- Parameters:
- key - the name of resource in form <namespace>.<resource name>
- Returns:
- The resource object.
- Throws:
- ECSystemException - If an error occurs, an exception is thrown.
lookup
public static final java.lang.Object lookup(java.lang.String name_space,
java.lang.String inst_name)
throws ECSystemException
- Gets the resource from the cache. If no locale is specified, the default server locale is used if the resource is locale-dependant.
-
- Parameters:
- name_space - the locale of resource
- inst_name - the name of resource
- Returns:
- The resource object.
- Throws:
- ECSystemException - If an error occurs, an exception is thrown.
lookup
public static final java.lang.Object lookup(java.lang.String name_space,
java.lang.String inst_name,
java.util.Locale locale)
throws ECSystemException
- Gets the resource from the cache.
-
- Parameters:
- name_space - the locale of resource
- inst_name - the name of resource
- locale - the version of resource to retrieve
- Returns:
- The resource object.
- Throws:
- ECSystemException - If an error occurs, an exception is thrown.
lookup
public static final java.lang.Object lookup(java.lang.String key,
java.util.Locale locale)
throws ECSystemException
- Gets the resource from the cache.
-
- Parameters:
- key - the name of resource in form <namespace>.<resource name>
- locale - the version of resource to retrieve
- Returns:
- The resource object.
- Throws:
- ECSystemException - If an error occurs, an exception is thrown.
Feedback
(C) Copyright IBM Corporation 1996, 2005. All Rights Reserved.