java.lang.Object | +--com.ibm.commerce.registry.LanguageRegistry
This is the Language Registry.
Field Summary | |
---|---|
protected
java.util.Hashtable |
cache |
protected
int |
cacheSize |
protected
static LanguageRegistry |
singleton |
Fields inherited from interface com.ibm.commerce.registry. Registry |
COPYRIGHT |
Constructor Summary | |
---|---|
protected |
LanguageRegistry() Constructor for LanguageRegistry. |
Method Summary | |
---|---|
void |
addElement(java.lang.Integer langId,
java.lang.Object bean) Adds a LanguageAccessBean to the local cache. |
void |
addElement(java.lang.Integer langId, java.lang.Object bean,
java.util.Hashtable aCache) Adds a LanguageAccessBean to the given cache. |
LanguageAccessBean |
find(java.lang.Integer langId) Finds a Langauge object from the Language registry. |
java.util.Enumeration |
getAll() Returns an Enumeration of all language Access Beans defined. |
java.lang.String |
getEncoding(java.lang.Integer langId) Returns the encoding string associated with a Langauge id. |
java.util.Locale |
getLocale(java.lang.Integer langId) Returns the locale associated with the Langauge object from the Language registry. |
void |
initialize() Initializes the LanguageRegistry. |
void |
refresh() Refreshes the local cache of lanaguage objects by retreiving them from the data base. |
void |
removeAllElements() Removes all LanguageAccessBean from the local cache. |
void |
removeElement(java.lang.Integer langId) Removes an LanguageAccessBean from the local cache. |
static
LanguageRegistry |
singleton() Returns a singleton Language Registry object |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll,
toString, wait, wait, wait |
Field Detail |
---|
protected java.util.Hashtable cache
protected int cacheSize
protected static LanguageRegistry singleton
Constructor Detail |
---|
protected LanguageRegistry()
Method Detail |
---|
public void addElement(java.lang.Integer langId, java.lang.Object bean)
langId
- the language Idbean
- the LanguageAccessBean to be added to the local
cachepublic void addElement(java.lang.Integer langId, java.lang.Object bean, java.util.Hashtable aCache)
langId
- the language Idbean
- the LanguageAccessBean to be addedaCache
- the cache object to be usedpublic LanguageAccessBean find(java.lang.Integer langId)
langId
- language Idpublic java.util.Enumeration getAll()
public java.lang.String getEncoding(java.lang.Integer langId)
public java.util.Locale getLocale(java.lang.Integer langId)
public void initialize() throws java.lang.Exception
initialize
in interface
Registry
java.lang.Exception
public void refresh() throws java.lang.Exception
refresh
in interface
Registry
java.lang.Exception
public void removeAllElements()
public void removeElement(java.lang.Integer langId)
langId
- the language Id associated with the
LanguageAccessBeanpublic static LanguageRegistry singleton()