org.apache.tomcat.maven.common.messages
Class DefaultMessagesProvider
java.lang.Object
org.apache.tomcat.maven.common.messages.DefaultMessagesProvider
- All Implemented Interfaces:
- MessagesProvider
@Component(role=MessagesProvider.class)
public class DefaultMessagesProvider
- extends Object
- implements MessagesProvider
- Since:
- 2.0
- Author:
- Olivier Lamy
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultMessagesProvider
public DefaultMessagesProvider()
getResourceBundle
public ResourceBundle getResourceBundle()
getMessage
public String getMessage(String key)
- Gets the message for the given key from this packages resource bundle.
- Specified by:
getMessage
in interface MessagesProvider
- Parameters:
key
- the key for the required message
- Returns:
- the message
getMessage
public String getMessage(String key,
Object... params)
- Gets the message for the given key from this packages resource bundle and formats it with the given parameter.
- Specified by:
getMessage
in interface MessagesProvider
- Parameters:
key
- the key for the required messageparams
- the parameters to be used to format the message with
- Returns:
- the formatted message
Copyright © 2005–2013 The Apache Software Foundation. All rights reserved.