org.jaffa.presentation.portlet.session
Class LocaleContext

java.lang.Object
  extended byorg.jaffa.presentation.portlet.session.LocaleContext

public class LocaleContext
extends Object

This class has a ThreadLocal variable to store the locale for a given Thread. It should be invoked by the controller servlet or the WebServices wrapper.


Constructor Summary
LocaleContext()
           
 
Method Summary
static Locale getLocale()
          This retrieves the locale object from the variable thread If no value exists, then the default locale for the JVM will be returned.
static void setLocale(Locale locale)
          This sets the Locale object from the request stream into the variable thread
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocaleContext

public LocaleContext()
Method Detail

setLocale

public static void setLocale(Locale locale)
This sets the Locale object from the request stream into the variable thread

Parameters:
locale - this is a locale object

getLocale

public static Locale getLocale()
This retrieves the locale object from the variable thread If no value exists, then the default locale for the JVM will be returned.

Returns:
returns a locale object


Copyright © 2002-2004 JAFFA Project.