There is one more thing, please check lines 306-312 of ParametersInterceptor - we have two layers where parameter must be accepted: 1. ParametersInterceptor 2. MemberAccessValueStack
and both must behave in the same way in case of ParameterNameAware. And ParameterNameAware should be used to relax restrictions set by acceptParams/excludeParams in ParametersInterceptor - like Paul said - a workaround. Regards -- Ćukasz + 48 606 323 122 http://www.lenart.org.pl/ 2013/7/24 Paul Benedict <[email protected]>: > Was the interface intended to workaround the interceptor? I find the > dueling unexpected. > On Jul 23, 2013 2:26 PM, "[email protected]" <[email protected]> wrote: > >> I'm working on issue https://issues.apache.org/jira/browse/WW-4137 >> >> Though we don't need to change the source code to address the reported >> issue >> I think we may want to change the JavaDoc for the ParameterNameAware >> interface. >> >> The JavaDoc for the ParametersInterceptor - >> >> http://struts.apache.org/release/2.3.x/xwork-core/apidocs/com/opensymphony/xwork2/interceptor/ParametersInterceptor.html >> has this warning: >> >> Using ParameterNameAware could be dangerous as @{link >> ParameterNameAware#acceptableParameterName(String)} takes precedence over >> ParametersInterceptor which means if ParametersInterceptor excluded given >> parameter name you can accept it with >> >> What I understand the above to mean (after reviewing the source code of the >> ParametersInterceptor) is that if my Action class implements >> ParameterNameAware then the acceptableParameterName method I define in my >> action is the only reference for filtering which parameters and values >> should be added to the Value stack. So using ParameterNameAware does away >> with the additional protection provided by the ParametersInterceptor. >> >> If my understanding is correct should I add the warning to the >> ParamenterNameAware interface's JavaDoc? >> >> Bruce >> >> >> >> -- >> View this message in context: >> http://struts.1045723.n5.nabble.com/Add-to-ParameterNameAware-JavaDoc-Warning-About-Using-tp5713285.html >> Sent from the Struts - Dev mailing list archive at Nabble.com. >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> >> --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
