@Component(role=MessagesProvider.class) public class DefaultMessagesProvider extends Object implements MessagesProvider
Constructor and Description |
---|
DefaultMessagesProvider() |
Modifier and Type | Method and Description |
---|---|
String |
getMessage(String key)
Gets the message for the given key from this packages resource bundle.
|
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.
|
ResourceBundle |
getResourceBundle() |
public ResourceBundle getResourceBundle()
public String getMessage(String key)
getMessage
in interface MessagesProvider
key
- the key for the required messagepublic String getMessage(String key, Object... params)
getMessage
in interface MessagesProvider
key
- the key for the required messageparams
- the parameters to be used to format the message withCopyright © 2005–2014 The Apache Software Foundation. All rights reserved.