Interface InternationalMessageSupport
- All Known Implementing Classes:
InternationalMessageServiceImpl
public interface InternationalMessageSupport
InternationalMessageService functionality, primarily in support of InternationalMessageOverrideStrategy instances.- Author:
- Jeff Fischer
-
Method Summary
Modifier and TypeMethodDescriptionfindBestStandardMessage(String specificPropertyKey, String generalPropertyKey, Map<String, org.broadleafcommerce.common.extension.StandardCacheItem> propertyTranslationMap) Find the most appropriate message in the map.findBestTemplateMessage(String specificPropertyKey, String generalPropertyKey, Map<String, InternationalMessage> propertyTranslationMap) Find the most appropriate message in the map.getCacheKey(String propertyName, org.broadleafcommerce.common.extension.ResultType resultType) Build a cache keygetCacheKeyListForTemplateSite(String propertyName) Returns a list of cacheKeys for a template sitejavax.cache.CacheRetrieve the backing cacheintRetrieve the threshold under which the full list of template catalog messages are cached.intRetrieve the threshold under which the full list of standard site message overrides are cached.org.broadleafcommerce.common.extension.StandardCacheItemlookupMessageFromMap(String key, Map<String, org.broadleafcommerce.common.extension.StandardCacheItem> propertyTranslationMap) Look up a cached message from the map based on a keyvoidsetTemplateThresholdForFullCache(int templateThresholdForFullCache) voidsetThresholdForFullCache(int thresholdForFullCache)
-
Method Details
-
getInternationalMessageCache
javax.cache.Cache getInternationalMessageCache()Retrieve the backing cache- Returns:
-
getThresholdForFullCache
int getThresholdForFullCache()Retrieve the threshold under which the full list of standard site message overrides are cached. SeeInternationalMessageServiceImpl.thresholdForFullCachefor more information on setting the value.- Returns:
-
setThresholdForFullCache
void setThresholdForFullCache(int thresholdForFullCache) -
getTemplateThresholdForFullCache
int getTemplateThresholdForFullCache()Retrieve the threshold under which the full list of template catalog messages are cached. SeeInternationalMessageServiceImpl.templateThresholdForFullCachefor more information on setting the value.- Returns:
-
setTemplateThresholdForFullCache
void setTemplateThresholdForFullCache(int templateThresholdForFullCache) -
findBestStandardMessage
InternationalMessage findBestStandardMessage(String specificPropertyKey, String generalPropertyKey, Map<String, org.broadleafcommerce.common.extension.StandardCacheItem> propertyTranslationMap) Find the most appropriate message in the map. The most specific qualified message will win.- Parameters:
specificPropertyKey-generalPropertyKey-propertyTranslationMap-- Returns:
-
lookupMessageFromMap
org.broadleafcommerce.common.extension.StandardCacheItem lookupMessageFromMap(String key, Map<String, org.broadleafcommerce.common.extension.StandardCacheItem> propertyTranslationMap) Look up a cached message from the map based on a key- Parameters:
key-propertyTranslationMap-- Returns:
-
findBestTemplateMessage
InternationalMessage findBestTemplateMessage(String specificPropertyKey, String generalPropertyKey, Map<String, InternationalMessage> propertyTranslationMap) Find the most appropriate message in the map. The most specific qualified message will win.- Parameters:
specificPropertyKey-generalPropertyKey-propertyTranslationMap-- Returns:
-
getCacheKey
String getCacheKey(String propertyName, org.broadleafcommerce.common.extension.ResultType resultType) Build a cache key- Parameters:
propertyName-resultType-- Returns:
-
getCacheKeyListForTemplateSite
Returns a list of cacheKeys for a template site- Parameters:
propertyName-- Returns:
-