com.retek.commons.gui.util
Class LanguageTranslator

java.lang.Object
  extended bycom.retek.commons.gui.util.TranslatorManager
      extended bycom.retek.commons.gui.util.LanguageTranslator

public class LanguageTranslator
extends TranslatorManager

This class provides translation for labels and other short language translations.

Retek Inc. Copyright (c) 2002


Field Summary
 
Fields inherited from class com.retek.commons.gui.util.TranslatorManager
EMPTY
 
Constructor Summary
LanguageTranslator()
          Returns new LanguageManager object.
LanguageTranslator(java.util.Locale locale, java.lang.String filename)
          Returns new LanguageManager object.
LanguageTranslator(java.lang.String filename)
          Returns new LanguageManager object.
 
Method Summary
 java.lang.String getText(java.lang.String text)
          Retrieves the translation for a specific label of screen text.
 
Methods inherited from class com.retek.commons.gui.util.TranslatorManager
getBundle, getLocale, setBundle, setLocale, setLocale
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LanguageTranslator

public LanguageTranslator()
Returns new LanguageManager object.


LanguageTranslator

public LanguageTranslator(java.lang.String filename)
                   throws UiBundleException
Returns new LanguageManager object.

Parameters:
filename - The filename of the properties file to load.
Throws:
UiBundleException - Thrown if the method fails to load the properties file.

LanguageTranslator

public LanguageTranslator(java.util.Locale locale,
                          java.lang.String filename)
                   throws UiBundleException
Returns new LanguageManager object.

Parameters:
locale - The Locale to load the label translations for.
filename - The filename of the properties file to load.
Throws:
UiBundleException - Thrown if the method fails to load the properties file.
Method Detail

getText

public java.lang.String getText(java.lang.String text)
Retrieves the translation for a specific label of screen text. If no translation exists, the original source text is returned.

Parameters:
text - The text to translate.
Returns:
The tranlated text.


Copyright © 2005 Retek Inc. All Rights Reserved. - Generated at Fri, 01/21/2005 14:25