com.atlassian.confluence.util.i18n
Class ResourceBundlesCollector
java.lang.Object
com.atlassian.confluence.util.i18n.ResourceBundlesCollector
public class ResourceBundlesCollector
- extends Object
Class that:
- takes a map of resource bundles (keyed by locale) or single resource bundles
- sorts them by locale
- combines all bundles keyed by the same locale into one CombinedResourceBundle
- and returns a list of CombinedResourceBundles in the correct locale order (most specific locales come first. e.g. fr_FR -> fr -> )
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ResourceBundlesCollector
public ResourceBundlesCollector()
addBundle
public void addBundle(ResourceBundle bundle)
- Adds a resource bundle that is not tied to any particular locale
- Parameters:
bundle
- resource bundle to add
addBundles
public void addBundles(Map<String,ResourceBundle> bundlesByLocale)
getCombinedResourceBundles
public List<ResourceBundle> getCombinedResourceBundles()