Class ClasspathAwareMessageSource

java.lang.Object
org.springframework.context.support.MessageSourceSupport
org.springframework.context.support.AbstractMessageSource
org.springframework.context.support.AbstractResourceBasedMessageSource
org.springframework.context.support.ReloadableResourceBundleMessageSource
de.hybris.platform.commercewebservices.core.util.ws.impl.ClasspathAwareMessageSource
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.context.HierarchicalMessageSource, org.springframework.context.MessageSource, org.springframework.context.ResourceLoaderAware

public class ClasspathAwareMessageSource extends org.springframework.context.support.ReloadableResourceBundleMessageSource
MessageSource which can be aware of OCC extensions and extract messages bundles from them.
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.springframework.context.support.ReloadableResourceBundleMessageSource

    org.springframework.context.support.ReloadableResourceBundleMessageSource.PropertiesHolder
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final org.springframework.core.io.ContextResource
     
    protected static final Function<org.springframework.core.io.ContextResource,String>
     
    protected static final Predicate<String>
     
    protected final org.springframework.core.io.support.PathMatchingResourcePatternResolver
     

    Fields inherited from class org.springframework.context.support.MessageSourceSupport

    logger
  • Constructor Summary

    Constructors
    Constructor
    Description
    ClasspathAwareMessageSource(org.springframework.core.io.ContextResource baseOccExtensionDir)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected org.springframework.core.io.ContextResource
     
    protected Set<String>
     
    protected String
    mapToMessageBundleFilePath(org.springframework.core.io.Resource resource)
     
    protected String
     
    void
     
    protected boolean
     

    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

    Methods inherited from class org.springframework.context.support.MessageSourceSupport

    createMessageFormat, formatMessage, isAlwaysUseMessageFormat, renderDefaultMessage, setAlwaysUseMessageFormat

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

    • FILE_FILTER

      protected static final Predicate<String> FILE_FILTER
    • classpathResourceMapper

      protected static final Function<org.springframework.core.io.ContextResource,String> classpathResourceMapper
    • baseOccExtensionDir

      protected final org.springframework.core.io.ContextResource baseOccExtensionDir
    • resolver

      protected final org.springframework.core.io.support.PathMatchingResourcePatternResolver resolver
  • Constructor Details

    • ClasspathAwareMessageSource

      public ClasspathAwareMessageSource(org.springframework.core.io.ContextResource baseOccExtensionDir)
  • Method Details

    • setupMessages

      @PostConstruct public void setupMessages()
    • getMessagesSet

      protected Set<String> getMessagesSet()
    • mapToMessageBundleFilePath

      protected String mapToMessageBundleFilePath(org.springframework.core.io.Resource resource)
    • validateFilename

      protected boolean validateFilename(String path)
    • mapToMessageBundlePath

      protected String mapToMessageBundlePath(String filePath)
    • getBaseOccExtensionDir

      protected org.springframework.core.io.ContextResource getBaseOccExtensionDir()