Code example for MessageFormat

Methods: formatsetLocale

   * @param parameters the parameter collection for the message 
   * @return the formated string 
  public String formatMessage(final String key, final Object[] parameters)
    final MessageFormat format = new MessageFormat(strictString(key));
    return format.format(parameters);
  public String getString(final String key, final Object[] parameters)
      return formatMessage(key, parameters);
    catch (MissingResourceException mre)
      logger.warn("ResourceBundleSupport#getString(,,)", mre);
      return '!' + key + '!';
Connect your IDE to all the code out there  Get Codota for Java