Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The installation preferences can be configured statically in spring. The user-specific and request-specific preferences can be configured in the portlet context (implementing request-specific ones as request parameter processor components). It's not clear how something like portlet-window-specific preference would be delivered to the locale manager (it's pretty much query-specific).Currently the framework will use locale manager in two ways:

  • resolving locale for a specific portlet window
  • resolving locale for a portal context component, such as an XSLT transformer
Code Block
titleILocaleManager methods

/**
 * This is a general method that can be used to resolve
 * locale for various components
 * @param availableLocales unordered set of supported locales
 * @return best matching locale given various locale preferences
 **/
 public Locale resolveLocale(Set availableLocales);

/**
 * This is a specific framework method for resolving
 * locale for a specific portlet window
 * 
 * Note: the initial implementation can just call method above
 * with locales provided by portletWindow.getSupportedLocales().
 * This will automatically support locale preferences/restrictions
 * defined at publish or subscribe time.
 * After that, we can add ability to specify locale preferences
 * for a specific portlet window, but that can be left for another 
 * milestone.
 *
 **/
 public Locale resolveLocale(IPortletWindow portletWindow);