org.apache.tiles.locale.impl
Class DefaultLocaleResolver
java.lang.Object
org.apache.tiles.locale.impl.DefaultLocaleResolver
- All Implemented Interfaces:
- LocaleResolver
public class DefaultLocaleResolver
- extends Object
- implements LocaleResolver
Default implementation of LocaleResolver
It tries to take the locale from the session-scoped attribute
LOCALE_KEY
. If it is not found, it returns the
locale included in the request.
- Version:
- $Rev: 887725 $ $Date: 2009-12-06 13:02:10 -0500 (Sun, 06 Dec 2009) $
Field Summary |
static String |
LOCALE_KEY
The attribute name that is used to store the current locale. |
Method Summary |
Locale |
resolveLocale(org.apache.tiles.request.Request request)
Resolves the locale. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LOCALE_KEY
public static final String LOCALE_KEY
- The attribute name that is used to store the current locale.
- See Also:
- Constant Field Values
DefaultLocaleResolver
public DefaultLocaleResolver()
resolveLocale
public Locale resolveLocale(org.apache.tiles.request.Request request)
- Resolves the locale.
- Specified by:
resolveLocale
in interface LocaleResolver
- Parameters:
request
- The Tiles request object.
- Returns:
- The current locale for the current request.
Copyright © 2001-2012 Apache Software Foundation. All Rights Reserved.