public final class Messages
extends java.lang.Object
MessageFormat mechanism for substitution of parameters.MessageFormat| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
getString(java.lang.String key)
Lookup in the
ResourceBundle for the key in parameter. |
static java.lang.String |
getString(java.lang.String key,
java.lang.Object... params)
Lookup in the
ResourceBundle for the key in parameter. |
public static java.lang.String getString(java.lang.String key)
ResourceBundle for the key in parameter. If key is not found, returns !key!key - The key of the message in the resource file.!key! if not found).public static java.lang.String getString(java.lang.String key,
java.lang.Object... params)
ResourceBundle for the key in parameter. The parameters in ellipse are used through the
MessageFormat.format(String, Object...) method. If key is not found, returns '!'+key'!'+Arrays.toString(params).key - The key of the message.params - The array used by the inner message formatter class to replace informations in the message.'!'+key'!'+Arrays.toString(params) if not found. Using the array in
parameter to format the message.Copyright © 2004-2012. All Rights Reserved.