org.apache.struts.chain
Class AbstractSelectLocale

java.lang.Object
  extended byorg.apache.struts.chain.AbstractSelectLocale
All Implemented Interfaces:
org.apache.commons.chain.Command
Direct Known Subclasses:
SelectLocale

public abstract class AbstractSelectLocale
extends java.lang.Object
implements org.apache.commons.chain.Command

Select the Locale to be used for this request.

Version:
$Rev: 54933 $ $Date: 2004-10-16 18:04:52 +0100 (Sat, 16 Oct 2004) $
Author:
Craig R. McClanahan

Field Summary
private  java.lang.String localeKey
           
private  java.lang.String moduleConfigKey
           
 
Constructor Summary
AbstractSelectLocale()
           
 
Method Summary
 boolean execute(org.apache.commons.chain.Context context)
          Select the Locale to be used for this request.
protected abstract  java.util.Locale getLocale(org.apache.commons.chain.Context context)
          Return the Locale to be used for this request.
 java.lang.String getLocaleKey()
          Return the context attribute key under which the Locale for the current request is stored.
 java.lang.String getModuleConfigKey()
          Return the context attribute key under which the ModuleConfig for the currently selected application module will be stored.
 void setLocaleKey(java.lang.String localeKey)
          Set the context attribute key under which the Locale for the current request is stored.
 void setModuleConfigKey(java.lang.String moduleConfigKey)
          Set the context attribute key under which the ModuleConfig for the currently selected application module will be stored.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

localeKey

private java.lang.String localeKey

moduleConfigKey

private java.lang.String moduleConfigKey
Constructor Detail

AbstractSelectLocale

public AbstractSelectLocale()
Method Detail

getLocaleKey

public java.lang.String getLocaleKey()

Return the context attribute key under which the Locale for the current request is stored.


setLocaleKey

public void setLocaleKey(java.lang.String localeKey)

Set the context attribute key under which the Locale for the current request is stored.

Parameters:
localeKey - The new context attribute key

getModuleConfigKey

public java.lang.String getModuleConfigKey()

Return the context attribute key under which the ModuleConfig for the currently selected application module will be stored.


setModuleConfigKey

public void setModuleConfigKey(java.lang.String moduleConfigKey)

Set the context attribute key under which the ModuleConfig for the currently selected application module will be stored.

Parameters:
moduleConfigKey - The new context attribute key

execute

public boolean execute(org.apache.commons.chain.Context context)
                throws java.lang.Exception

Select the Locale to be used for this request.

Specified by:
execute in interface org.apache.commons.chain.Command
Parameters:
context - The Context for the current request
Returns:
false so that processing continues
Throws:
java.lang.Exception

getLocale

protected abstract java.util.Locale getLocale(org.apache.commons.chain.Context context)

Return the Locale to be used for this request.

Parameters:
context - The Context for this request


Copyright ? 2003 - Apache Software Foundation