public interface ITranslation
| Modifier and Type | Method and Description |
|---|---|
String |
getAttributeTranslation(String attributeName)
Gets the translation associated to an attribute.
|
Map<String,String> |
getAttributeTranslations()
Gets all the attribute translations which have been registered.
|
String |
getLanguageCode()
Gets the language code which define the language associated to the translations.
|
void |
setAttributeTranslation(String attributeName,
String attributeValue)
Add a translated attribute or update an existing one.
|
void |
setLanguageCode(String languageCode)
Sets the language code which define the language associated to the translations.
|
String getAttributeTranslation(String attributeName)
attributeName - The name of the attribute for which one to get translations.IllegalStateException - If no attribute translation corresponds to the specified name.Map<String,String> getAttributeTranslations()
String getLanguageCode()
WARNING: The language code returned by this function is always expressed in uppercase even if you set it using a lower case syntax. The translation class always stores language codes using an upper case syntax.
void setAttributeTranslation(String attributeName, String attributeValue)
attributeName - The name of the translated attribute.attributeValue - The value of the translated attribute, the language associated to this
value is defined by the `getLanguageCode()` and `setLanguageCode()` functions.void setLanguageCode(String languageCode)
WARNING: The provided language code is not case sensitive, but, internally the language code which is used and stored is ALWAYS converted in uppercase.
languageCode - The language code to set, this string must be compliant with the ISO639-1
standard.Copyright © 2017 GOMOOB. All rights reserved.