spring-framework / org.springframework.context.i18n / SimpleTimeZoneAwareLocaleContext

SimpleTimeZoneAwareLocaleContext

open class SimpleTimeZoneAwareLocaleContext : SimpleLocaleContext, TimeZoneAwareLocaleContext

Simple implementation of the TimeZoneAwareLocaleContext interface, always returning a specified Locale and TimeZone.

Note: Prefer the use of SimpleLocaleContext when only setting a Locale but no TimeZone.

Author
Juergen Hoeller

Author
Nicholas Williams

Since
4.0

See Also
LocaleContextHolder#setLocaleContextLocaleContextHolder#getTimeZone()

Constructors

<init>

SimpleTimeZoneAwareLocaleContext(locale: Locale, timeZone: TimeZone)

Create a new SimpleTimeZoneAwareLocaleContext that exposes the specified Locale and TimeZone. Every #getLocale() call will return the given Locale, and every #getTimeZone() call will return the given TimeZone.

Functions

getTimeZone

open fun getTimeZone(): TimeZone

toString

open fun toString(): String