DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=30292>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=30292

Replacement of LookupDispatchAction





------- Additional Comments From [EMAIL PROTECTED]  2004-07-23 22:29 -------
Niall.

My code was inspired by the code of DispatchAction from the Struts 1.1 release.
The execute method I overrode was basically cut'n pasted from this version of
DispatchAction, and nothing in this version is related to cancel behavior. The
method getMethodName() that you suggest to override doesn't exist in the 1.1
version of the DispatchAction either. Feel free to adapt my code to the newest
version of DispatchAction, of course.
Sorry also for the use of getParameterMap(). I looked for a @since entry in the
javadoc of this method, and there is none so I assumed it was there from the
beginning. The other obvious (but less performant) way to proceed is to loop
through the enumeration of request parameters.
Now for the question "Is it really needed?". I think this technique is more
powerful, easier to use, more flexible than the LookupDispatchAction, for all
the reasons I've mentioned in the submitted javadoc. Is it really *needed*? No,
because I could just use my own version of this class. But I think it provides a
real enhancement over LookupDispatchAction. BTW, LookupDispatchAction just seems
wrong to me: trying to get back a key from a value in internationalized
properties files and asking the developer to provide a mapping from button text
keys to method names just to select a method doesn't look right to me.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to