This class is provided as a convenience. Implementations of {@link Translator} are not required to use this class.
As one of its {@link hirondelle.web4j.StartupTasks}, a typical implementation of {@link Translator} may fetch a {@code List For looking up translations, the following nested {@link Map} structure is useful : (See {@link Translator} for definition of 'base text'.) The {@link #asNestedMap(Collection)} method will modify a {@code List Map[BaseText, Map[Locale, Translation]]
Here, BaseText and Translation are ordinary unescaped Strings, not {@link SafeText}. This is because the various translation tags in this package always first perform translation using ordinary unescaped Strings, and then perform any necessary escaping on the result of the translation. Usually String, but sometimes SafeText
The following style will remain consistent, and will not escape special characters twice :
The translation text usually remains as a String, yet {@link SafeText} is available when working with the data directly in a web page, in a form or listing.
|
|