[ http://issues.apache.org/struts/browse/STR-2739?page=all ] David Evans closed STR-2739: ----------------------------
> [extras] ParameterListActionDispatcher > -------------------------------------- > > Key: STR-2739 > URL: http://issues.apache.org/struts/browse/STR-2739 > Project: Struts Action 1 > Type: Improvement > Components: Extras > Versions: 1.3.0 > Environment: Operating System: other > Platform: Other > Reporter: Paul Benedict > Assignee: David Evans > Priority: Minor > Attachments: ParameterListActionDispatcher.java, > ParameterListActionDispatcher.java, ParameterListActionDispatcher.java, > ParameterMappingDispatchAction.java, ParameterMappingDispatchAction.java > > The attached ParameterMappingDispatchAction class is a proposed enhancement to > MappingDispatchAction either as a subclass or a direct replacement. Here are > the > added benefits: > 1) For a form with multiple buttons, the parameter attribute can contain a > list > of appropriate methods to iterate for a match. These methods are matched > against > incoming request parameters (as well as button .x/.y suffixes). For security > reasons, a developer may want to limit which methods to invoke for a > particular > mapping, unlike DispatchAction which will match any existing method. > <action ... parameter="save,apply,back"/> > 2) ParameterMappingDispatchAction provided the ability to also obfuscate > method > names, and so does this by providing a key=value mapping. The key will be the > request parameter name and the value the method name. > <action ... parameter="save,apply=saveAndReturn,back=goBack"/> > 3) Sometimes the user presses Enter to submit the form and no button is > explicitly submitted. When this case is important to catch, the action may > invoke the "default" method if nothing matches. In this example, the default > is > to save. > <action ... parameter="save,apply,back,default=save"/> > 4) When only one method is listed, the method returns it to equal > functionality > to MappingDispatchAction. > <action ... parameter="save"/> -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/struts/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]