|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.springframework.format.datetime.joda.JodaTimeContextHolder
public final class JodaTimeContextHolder
A holder for a thread-local user JodaTimeContext.
| Constructor Summary | |
|---|---|
JodaTimeContextHolder()
|
|
| Method Summary | |
|---|---|
static org.joda.time.format.DateTimeFormatter |
getFormatter(org.joda.time.format.DateTimeFormatter formatter,
Locale locale)
Obtain a DateTimeFormatter with user-specific settings applied to the given base Formatter. |
static JodaTimeContext |
getJodaTimeContext()
Return the JodaTimeContext associated with the current thread, if any. |
static void |
resetJodaTimeContext()
Reset the JodaTimeContext for the current thread. |
static void |
setJodaTimeContext(JodaTimeContext jodaTimeContext)
Associate the given JodaTimeContext with the current thread. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JodaTimeContextHolder()
| Method Detail |
|---|
public static void resetJodaTimeContext()
public static void setJodaTimeContext(JodaTimeContext jodaTimeContext)
jodaTimeContext - the current JodaTimeContext,
or null to reset the thread-bound contextpublic static JodaTimeContext getJodaTimeContext()
null if none
public static org.joda.time.format.DateTimeFormatter getFormatter(org.joda.time.format.DateTimeFormatter formatter,
Locale locale)
formatter - the base formatter that establishes default formatting rules
(generally user independent)locale - the current user locale (may be null if not known)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||