Package com.evolveum.midpoint.common
Class CachedResourceBundleMessageSource
java.lang.Object
org.springframework.context.support.MessageSourceSupport
org.springframework.context.support.AbstractMessageSource
org.springframework.context.support.AbstractResourceBasedMessageSource
org.springframework.context.support.ResourceBundleMessageSource
com.evolveum.midpoint.common.CachedResourceBundleMessageSource
- All Implemented Interfaces:
org.springframework.beans.factory.Aware
,org.springframework.beans.factory.BeanClassLoaderAware
,org.springframework.context.HierarchicalMessageSource
,org.springframework.context.MessageSource
public class CachedResourceBundleMessageSource
extends org.springframework.context.support.ResourceBundleMessageSource
Looking for resource bundle in compressed JAR and compressed libraries inside JAR is pretty expensive.
Therefore this implementation caches information about whether bundle exists.
- Author:
- Viliam Repan (lazyman).
-
Field Summary
Fields inherited from class org.springframework.context.support.MessageSourceSupport
logger
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected ResourceBundle
getResourceBundle
(String basename, Locale locale) Methods inherited from class org.springframework.context.support.ResourceBundleMessageSource
doGetBundle, getBundleClassLoader, getMessageFormat, getStringOrNull, loadBundle, loadBundle, resolveCode, resolveCodeWithoutArguments, setBeanClassLoader, setBundleClassLoader, 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
Methods inherited from class org.springframework.context.support.MessageSourceSupport
createMessageFormat, formatMessage, isAlwaysUseMessageFormat, renderDefaultMessage, setAlwaysUseMessageFormat
-
Constructor Details
-
CachedResourceBundleMessageSource
public CachedResourceBundleMessageSource()
-
-
Method Details
-
getResourceBundle
- Overrides:
getResourceBundle
in classorg.springframework.context.support.ResourceBundleMessageSource
-