| java.lang.Object org.apache.struts.action.Action org.apache.struts.webapp.validator.LocaleAction
LocaleAction | final public class LocaleAction extends Action (Code) | | Implementation of Action that changes the user's
java.util.Locale and forwards to a page, based on request level
parameters that are set (language, country, & page).
|
execute | public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception(Code) | |
Change the user's
java.util.Locale based on
ActionForm properties.
This Action looks for language and
country properties on the given form, constructs an
appropriate Locale object, and sets it as the Struts Locale for this
user's session.
Any ActionForm, including a
DynaActionForm , may be used.
If a page property is also provided, then after
setting the Locale, control is forwarded to that URI path.
Otherwise, control is forwarded to "success".
Parameters: mapping - The ActionMapping used to select this instance Parameters: form - The optional ActionForm bean for this request (if any) Parameters: request - The HTTP request we are processing Parameters: response - The HTTP response we are creating Action to forward to exception: java.lang.Exception - if an input/output error or servlet exception occurs |
Methods inherited from org.apache.struts.action.Action | protected void addErrors(HttpServletRequest request, ActionMessages errors)(Code)(Java Doc) protected void addMessages(HttpServletRequest request, ActionMessages messages)(Code)(Java Doc) public ActionForward execute(ActionMapping mapping, ActionForm form, ServletRequest request, ServletResponse response) throws Exception(Code)(Java Doc) public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception(Code)(Java Doc) protected String generateToken(HttpServletRequest request)(Code)(Java Doc) protected ActionMessages getErrors(HttpServletRequest request)(Code)(Java Doc) protected Locale getLocale(HttpServletRequest request)(Code)(Java Doc) protected ActionMessages getMessages(HttpServletRequest request)(Code)(Java Doc) protected MessageResources getResources(HttpServletRequest request)(Code)(Java Doc) protected MessageResources getResources(HttpServletRequest request, String key)(Code)(Java Doc) public ActionServlet getServlet()(Code)(Java Doc) protected boolean isCancelled(HttpServletRequest request)(Code)(Java Doc) protected boolean isTokenValid(HttpServletRequest request)(Code)(Java Doc) protected boolean isTokenValid(HttpServletRequest request, boolean reset)(Code)(Java Doc) protected void resetToken(HttpServletRequest request)(Code)(Java Doc) protected void saveErrors(HttpServletRequest request, ActionMessages errors)(Code)(Java Doc) protected void saveErrors(HttpSession session, ActionMessages errors)(Code)(Java Doc) protected void saveMessages(HttpServletRequest request, ActionMessages messages)(Code)(Java Doc) protected void saveMessages(HttpSession session, ActionMessages messages)(Code)(Java Doc) protected void saveToken(HttpServletRequest request)(Code)(Java Doc) protected void setLocale(HttpServletRequest request, Locale locale)(Code)(Java Doc) public void setServlet(ActionServlet servlet)(Code)(Java Doc)
|
|
|