|
Venice 0.7beta | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.mov.util.Locale
public class Locale
This class implements internationalisation support for Venice. Each text message displayed by Venice is represented by a string symbol (e.g. "OPEN") which describes the error message being displayed. This symbol is then matched to a internationalistaion file which will then retrieve the local language version of that error message.
If a match could not be found in the current language, it will try to match the
symbol in the english (default) language. If it could not find a match there,
it will display the string Locale.UNKNOWN
.
The internationalisation files are kept in src/org/mov/util/locale/.
ResourceBundle
Method Summary | |
---|---|
static java.util.Locale |
getLocale()
Get the localization. |
static java.lang.String |
getString(java.lang.String key)
Return the current language translation of the text associated with the given key. |
static java.lang.String |
getString(java.lang.String key,
double arg1,
double arg2)
Return the current language translation of the text associated with the given key. |
static java.lang.String |
getString(java.lang.String key,
int arg1)
Return the current language translation of the text associated with the given key. |
static java.lang.String |
getString(java.lang.String key,
int arg1,
int arg2)
Return the current language translation of the text associated with the given key. |
static java.lang.String |
getString(java.lang.String key,
int arg1,
int arg2,
int arg3)
|
static java.lang.String |
getString(java.lang.String key,
java.lang.String arg1)
Return the current language translation of the text associated with the given key. |
static java.lang.String |
getString(java.lang.String key,
java.lang.String arg1,
java.lang.String arg2)
Return the current language translation of the text associated with the given key. |
static java.lang.String |
getString(java.lang.String key,
java.lang.String arg1,
java.lang.String arg2,
java.lang.String arg3)
Return the current language translation of the text associated with the given key. |
static void |
setLocale()
Set the localization as got from saved preferences. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static void setLocale()
public static java.util.Locale getLocale()
public static java.lang.String getString(java.lang.String key)
key
- a key which represents a line of text
public static java.lang.String getString(java.lang.String key, java.lang.String arg1)
Generation %1The first argument will replace
%1
.
key
- a key which represents a line of textarg1
- the first argument
public static java.lang.String getString(java.lang.String key, java.lang.String arg1, java.lang.String arg2)
Generation %1 of %2The first argument will replace
%1
and the second
argument will replace %2
.
key
- a key which represents a line of textarg1
- the first argumentarg2
- the second argument
public static java.lang.String getString(java.lang.String key, java.lang.String arg1, java.lang.String arg2, java.lang.String arg3)
%1 of %2 (%3%)The first argument will replace
%1
and the second
argument will replace %2
and the third argument
will replace %3
.
key
- a key which represents a line of textarg1
- the first argumentarg2
- the second argumentarg3
- the third argument
public static java.lang.String getString(java.lang.String key, int arg1)
Generation %1The first argument will replace
%1
.
key
- a key which represents a line of textarg1
- the first argument
public static java.lang.String getString(java.lang.String key, int arg1, int arg2)
Generation %1 of %2The first argument will replace
%1
and the second
argument will replace %2
.
key
- a key which represents a line of textarg1
- the first argumentarg2
- the second argument
public static java.lang.String getString(java.lang.String key, int arg1, int arg2, int arg3)
public static java.lang.String getString(java.lang.String key, double arg1, double arg2)
Generation %1 of %2The first argument will replace
%1
and the second
argument will replace %2
.
key
- a key which represents a line of textarg1
- the first argumentarg2
- the second argument
|
Venice 0.7beta | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |