public class FixedTranslation extends Object implements Translation
Constructor and Description |
---|
FixedTranslation(String value)
Create a new translation with an id and value that are the same.
|
Modifier and Type | Method and Description |
---|---|
String |
get(Locale locale)
Gets the translation without any parameters replaced.
|
String |
get(Locale locale,
Object... args)
Gets the translation format with the specified parameters.
|
String |
getId()
Gets the identifier for this
Translation . |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
get, get
public FixedTranslation(String value)
value
- The id and valuepublic String getId()
Translation
Translation
.getId
in interface Translation
public String get(Locale locale)
Translation
get
in interface Translation
locale
- The language to get the translated format string forpublic String get(Locale locale, Object... args)
Translation
get
in interface Translation
locale
- The language to get the translated string forargs
- The parameters for this translation