Class AbstractLocaleResolver

java.lang.Object
org.springframework.web.servlet.i18n.AbstractLocaleResolver
All Implemented Interfaces:
LocaleResolver
Direct Known Subclasses:
AbstractLocaleContextResolver, AcceptHeaderLocaleResolver

public abstract class AbstractLocaleResolver extends Object implements LocaleResolver
Abstract base class for LocaleResolver implementations.

Provides support for a default locale.

Since:
1.2.9
Author:
Juergen Hoeller
See Also:
  • Constructor Details

    • AbstractLocaleResolver

      public AbstractLocaleResolver()
  • Method Details

    • setDefaultLocale

      public void setDefaultLocale(@Nullable Locale defaultLocale)
      Set a default Locale that this resolver will return if no other locale is found.
    • getDefaultLocale

      @Nullable protected Locale getDefaultLocale()
      Get the default Locale that this resolver is supposed to fall back to, if any.