Class EntityPropertiesServiceSpringImpl.SpringMessageBundle
- java.lang.Object
-
- org.springframework.context.support.MessageSourceSupport
-
- org.springframework.context.support.AbstractMessageSource
-
- org.springframework.context.support.AbstractResourceBasedMessageSource
-
- org.springframework.context.support.ReloadableResourceBundleMessageSource
-
- org.sakaiproject.entitybroker.util.spring.EntityPropertiesServiceSpringImpl.SpringMessageBundle
-
- All Implemented Interfaces:
AbstractEntityPropertiesService.MessageBundle,org.springframework.beans.factory.Aware,org.springframework.context.HierarchicalMessageSource,org.springframework.context.MessageSource,org.springframework.context.ResourceLoaderAware
- Enclosing class:
- EntityPropertiesServiceSpringImpl
protected class EntityPropertiesServiceSpringImpl.SpringMessageBundle extends org.springframework.context.support.ReloadableResourceBundleMessageSource implements AbstractEntityPropertiesService.MessageBundle
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSpringMessageBundle()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<String>getPropertyKeys(Locale locale)Get all the keys for a specific LocaleStringgetPropertyMessage(String key, Object[] args, Locale locale)Try to resolve the message.-
Methods inherited from class org.springframework.context.support.ReloadableResourceBundleMessageSource
calculateAllFilenames, calculateFilenamesForLocale, clearCache, clearCacheIncludingAncestors, getMergedProperties, getProperties, loadProperties, newProperties, refreshProperties, resolveCode, resolveCodeWithoutArguments, setConcurrentRefresh, setFileEncodings, setPropertiesPersister, setResourceLoader, toString
-
Methods inherited from class org.springframework.context.support.AbstractResourceBasedMessageSource
addBasenames, getBasenameSet, getCacheMillis, getDefaultEncoding, getDefaultLocale, isFallbackToSystemLocale, setBasename, setBasenames, setCacheMillis, setCacheSeconds, setDefaultEncoding, setDefaultLocale, setFallbackToSystemLocale
-
Methods inherited from class org.springframework.context.support.AbstractMessageSource
getCommonMessages, getDefaultMessage, getDefaultMessage, getMessage, getMessage, getMessage, getMessageFromParent, getMessageInternal, getParentMessageSource, isUseCodeAsDefaultMessage, resolveArguments, setCommonMessages, setParentMessageSource, setUseCodeAsDefaultMessage
-
-
-
-
Method Detail
-
getPropertyMessage
public String getPropertyMessage(String key, Object[] args, Locale locale)
Description copied from interface:AbstractEntityPropertiesService.MessageBundleTry to resolve the message. Treat as an error if the message can't be found.- Specified by:
getPropertyMessagein interfaceAbstractEntityPropertiesService.MessageBundle- Parameters:
key- the code to lookup up, such as 'calculator.noRateSet'args- Array of arguments that will be filled in for params within the message (params look like "{0}", "{1,date}", "{2,time}" within a message), ornullif none.locale- the Locale in which to do the lookup- Returns:
- the resolved message
-
getPropertyKeys
public List<String> getPropertyKeys(Locale locale)
Description copied from interface:AbstractEntityPropertiesService.MessageBundleGet all the keys for a specific Locale- Specified by:
getPropertyKeysin interfaceAbstractEntityPropertiesService.MessageBundle- Parameters:
locale- the Locale in which to do the lookup- Returns:
- the list of all keys found for the given Locale
-
-