public final class JAPMessages
extends java.lang.Object
http://www.w3.org/WAI/ER/IG/ert/iso639.htm
Modifier and Type | Method and Description |
---|---|
static java.util.Locale |
getLocale()
Returns the Locale that is used by this class to get the messages.
|
static java.lang.String |
getString(java.lang.String a_key)
Gets the localised String for a given key.
|
static java.lang.String |
getString(java.lang.String a_key,
java.lang.Object a_argument)
Gets the localised String for a given key.
|
static java.lang.String |
getString(java.lang.String a_key,
java.lang.Object[] a_arguments)
Gets the localised String for a given key.
|
static java.util.Locale |
getSystemLocale() |
static boolean |
init(java.util.Locale locale,
java.lang.String a_resourceBundleFilename)
Initialises the resource bundle with the specified Locale.
|
static boolean |
init(java.lang.String a_resourceBundleFilename)
Initialises the resource bundle with the System default Locale.
|
static boolean |
isInitialised() |
static void |
setLocale(java.util.Locale a_locale) |
public static java.util.Locale getSystemLocale()
public static boolean init(java.lang.String a_resourceBundleFilename)
a_resourceBundleFilename
- a file name for the resource bundle; the language code for the
locale will be added programmatically (e.g. _en, _de, ...).public static boolean init(java.util.Locale locale, java.lang.String a_resourceBundleFilename)
locale
- a Localea_resourceBundleFilename
- a file name for the resource bundle; the language code for the
locale will be added programmatically (e.g. _en, _de, ...).public static boolean isInitialised()
public static java.util.Locale getLocale()
public static void setLocale(java.util.Locale a_locale)
public static java.lang.String getString(java.lang.String a_key)
a_key
- a key for the localised Stringpublic static java.lang.String getString(java.lang.String a_key, java.lang.Object[] a_arguments)
java.text.MessageFormat
.a_key
- a key for the localised Stringa_arguments
- an object array that contains the objects that replaceMessageFormat
public static java.lang.String getString(java.lang.String a_key, java.lang.Object a_argument)
java.text.MessageFormat
.a_key
- a key for the localised Stringa_argument
- a object that is inserted into the message StringMessageFormat
Copyright © 2023. All rights reserved.