public abstract class AbstractMessageResolver extends Object implements MessageResolver
resolve(RuleResultDetail) which uses String.format(String,
Object...) to resolve messages. When no message is found for a particular key, the key and the RuleResultDetail.getParameters() are used to construct a message.| Constructor and Description |
|---|
AbstractMessageResolver() |
| Modifier and Type | Method and Description |
|---|---|
Locale |
getLocale()
Returns the locale used by this message resolver.
|
protected abstract String |
getMessage(String key)
Returns the message for the supplied key.
|
String |
resolve(RuleResultDetail detail)
Resolves the message for the supplied rule result detail.
|
void |
setLocale(Locale l)
Sets the locale used by this message resolver.
|
public Locale getLocale()
public void setLocale(Locale l)
l - localeprotected abstract String getMessage(String key)
key - which corresponds to a messagepublic String resolve(RuleResultDetail detail)
MessageResolverresolve in interface MessageResolverdetail - rule result detailCopyright © 2003-2024 Virginia Tech. All Rights Reserved.