public class DummyI18nManager extends Object implements I18nManager
I18nManager
implementation to be used when there has not been
registered an implementation.
Returns as value the same message to get the translation for.Constructor and Description |
---|
DummyI18nManager() |
Modifier and Type | Method and Description |
---|---|
void |
addResourceFamily(String family,
ClassLoader loader,
String callerName) |
void |
addResourceFamily(String family,
File folder)
Adds an additional family of resource files containing some translations.
|
String |
getTranslation(String message)
Get translation for the current language of message.
|
String |
getTranslation(String message,
String[] args)
Get translation for the current language of message.
|
public String getTranslation(String message)
I18nManager
getTranslation
in interface I18nManager
message
- the message key used for translation.public String getTranslation(String message, String[] args)
I18nManager
getTranslation
in interface I18nManager
message
- the message key used for translation.public void addResourceFamily(String family, ClassLoader loader, String callerName)
addResourceFamily
in interface I18nManager
public void addResourceFamily(String family, File folder)
I18nManager
i18nManager.addResourceFamily("text", new File("./resources"))
addResourceFamily
in interface I18nManager
family
- The family name (or base name) which is used to search
actual properties files.folder
- The search path to locate the property files