|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmondrian.gui.I18n
public class I18n
Constructor Summary | |
---|---|
I18n(java.util.ResourceBundle guiBundle,
java.util.ResourceBundle languageBundle)
|
Method Summary | |
---|---|
static void |
addOnLanguageChangedListener(LanguageChangedListener listener)
|
java.util.Locale |
getCurrentLocale()
|
static java.lang.String |
getCurrentLocaleID()
|
java.lang.String |
getFormattedString(java.lang.String stringId,
java.lang.String defaultValue,
java.lang.Object... args)
Retrieves a resource string using the current locale. |
java.lang.String |
getGUIReference(java.lang.String reference)
|
static java.util.List<java.util.Locale> |
getListOfAvailableLanguages(java.lang.Class cl)
|
static java.util.Set<java.lang.String> |
getResourcesInPackage(java.lang.Class coreClass,
java.lang.String packageName)
Enumerates the resouces in a give package name. |
java.lang.String |
getString(java.lang.String stringId)
Retreives a resource string using the current locale. |
java.lang.String |
getString(java.lang.String stringId,
java.util.Locale currentLocale,
java.lang.String defaultValue)
Retreive a resource string using the given locale. |
java.lang.String |
getString(java.lang.String stringId,
java.lang.String defaultValue)
Retreives a resource string using the current locale, with a default. |
void |
setCurrentLocale(java.util.Locale locale)
|
void |
setCurrentLocale(java.lang.String language)
|
void |
setCurrentLocale(java.lang.String language,
java.lang.String country)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public I18n(java.util.ResourceBundle guiBundle, java.util.ResourceBundle languageBundle)
Method Detail |
---|
public static void addOnLanguageChangedListener(LanguageChangedListener listener)
public static java.util.List<java.util.Locale> getListOfAvailableLanguages(java.lang.Class cl)
public static java.util.Set<java.lang.String> getResourcesInPackage(java.lang.Class coreClass, java.lang.String packageName) throws java.io.IOException
The resulting set is deterministically ordered.
coreClass
- Class for class loader to find the resourcespackageName
- The package to enumerate
java.io.IOException
public void setCurrentLocale(java.lang.String language)
public void setCurrentLocale(java.lang.String language, java.lang.String country)
public void setCurrentLocale(java.util.Locale locale)
public java.util.Locale getCurrentLocale()
public java.lang.String getGUIReference(java.lang.String reference)
public java.lang.String getString(java.lang.String stringId)
stringId
- The resource string identifier
public java.lang.String getString(java.lang.String stringId, java.lang.String defaultValue)
stringId
- The resource string identifierdefaultValue
- If no resource for the stringID is specified, use
this default value
public java.lang.String getFormattedString(java.lang.String stringId, java.lang.String defaultValue, java.lang.Object... args)
stringId
- The resource string identifierdefaultValue
- The default value for the resource stringargs
- arguments to be inserted into the resource string
public java.lang.String getString(java.lang.String stringId, java.util.Locale currentLocale, java.lang.String defaultValue)
stringId
- The resource string identifiercurrentLocale
- required Locale for resourcedefaultValue
- The default value for the resource string
public static java.lang.String getCurrentLocaleID()
|
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |