public class DefaultMessageSource extends AbstractMessageSource
EMPTY_OBJECT_ARGS, ERROR_ARGS_NULL, ERROR_KEY_BLANK, ERROR_LOCALE_NULL, ERROR_MESSAGE_NULL
REF_KEY_END, REF_KEY_START
Constructor and Description |
---|
DefaultMessageSource(CompositeResourceBundleBuilder builder,
String basename) |
Modifier and Type | Method and Description |
---|---|
ResourceBundle |
asResourceBundle()
Offers a view of this
MessageSource as a ResourceBundle . |
protected Object |
doResolveMessageValue(String key,
Locale locale) |
String |
getBasename() |
protected ResourceBundle |
getBundle(Locale locale) |
evalMessageWithArguments, evalMessageWithArguments, formatMessage, formatMessage, formatMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, getMessage, resolveMessageValue, toObjectArray
public DefaultMessageSource(@Nonnull CompositeResourceBundleBuilder builder, @Nonnull String basename)
@Nonnull protected Object doResolveMessageValue(@Nonnull String key, @Nonnull Locale locale) throws NoSuchResourceException
doResolveMessageValue
in class AbstractMessageSource
NoSuchResourceException
@Nonnull protected ResourceBundle getBundle(@Nonnull Locale locale)
@Nonnull public ResourceBundle asResourceBundle()
MessageSource
MessageSource
as a ResourceBundle
.ResourceBundle
containing the keys this MessageSource
can resolve.