|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.jonas.lib.util.I18n
public final class I18n
This class defines the way for getting message with ResourceBundle for different language. Inspired from http://java.sun.com/docs/books/tutorial/i18n/
| Method Summary | |
|---|---|
static I18n |
getInstance(Class<?> c)
Gets the instance for a given class. |
static I18n |
getInstance(Class<?> c,
ClassLoader cl)
Gets the instance for a given class. |
static I18n |
getInstance(String packageName)
Gets the instance for a given package. |
static I18n |
getInstance(String packageName,
ClassLoader cl)
Gets the instance for a given package. |
String |
getMessage(String key)
Gets the value of the given key. |
String |
getMessage(String key,
Object obj)
Gets the formatted string with the given arguments. |
String |
getMessage(String key,
Object[] args)
Gets the formatted string with the given arguments. |
String |
getMessage(String key,
Object obj1,
Object obj2)
Gets the formatted string with the given arguments. |
String |
getMessage(String key,
Object obj1,
Object obj2,
Object obj3)
Gets the formatted string with the given arguments. |
String |
getMessage(String key,
Object obj1,
Object obj2,
Object obj3,
Object obj4)
Gets the formatted string with the given arguments. |
String |
getMessage(String key,
Object obj1,
Object obj2,
Object obj3,
Object obj4,
Object obj5)
Gets the formatted string with the given arguments. |
String |
getMessage(String key,
Object obj1,
Object obj2,
Object obj3,
Object obj4,
Object obj5,
Object obj6)
Gets the formatted string with the given arguments. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static I18n getInstance(Class<?> c)
c - the class for which we want a bundle
public static I18n getInstance(Class<?> c,
ClassLoader cl)
c - the class for which we want a bundlecl - the classloader used to load bundle
public static I18n getInstance(String packageName)
packageName - the package for which we want a bundle
public static I18n getInstance(String packageName,
ClassLoader cl)
packageName - the package for which we want a bundlecl - the classloader used to load bundle
public String getMessage(String key,
Object[] args)
key - the keystring on which to apply argumentsargs - the object arguments for the formatter
public String getMessage(String key)
key - the keystring to retrieve
public String getMessage(String key,
Object obj)
key - the keystring on which to apply argumentsobj - the object argument for the formatter
public String getMessage(String key,
Object obj1,
Object obj2)
key - the keystring on which to apply argumentsobj1 - the first object argument for the formatterobj2 - the second object argument for the formatter
public String getMessage(String key,
Object obj1,
Object obj2,
Object obj3)
key - the keystring on which to apply argumentsobj1 - the first object argument for the formatterobj2 - the second object argument for the formatterobj3 - the third object argument for the formatter
public String getMessage(String key,
Object obj1,
Object obj2,
Object obj3,
Object obj4)
key - the keystring on which to apply argumentsobj1 - argument for the formatterobj2 - argument for the formatterobj3 - argument for the formatterobj4 - argument for the formatter
public String getMessage(String key,
Object obj1,
Object obj2,
Object obj3,
Object obj4,
Object obj5)
key - the keystring on which to apply argumentsobj1 - argument for the formatterobj2 - argument for the formatterobj3 - argument for the formatterobj4 - argument for the formatterobj5 - argument for the formatter
public String getMessage(String key,
Object obj1,
Object obj2,
Object obj3,
Object obj4,
Object obj5,
Object obj6)
key - the keystring on which to apply argumentsobj1 - argument for the formatterobj2 - argument for the formatterobj3 - argument for the formatterobj4 - argument for the formatterobj5 - argument for the formatterobj6 - argument for the formatter
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||