2011/7/5 <[email protected]>:
> Author: markt
> Date: Tue Jul 5 10:03:06 2011
> New Revision: 1142953
>
> URL: http://svn.apache.org/viewvc?rev=1142953&view=rev
> Log:
> Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=51472
> Correctly test modifiers when resolving bean methods with the BeanELResolver.
> Patch provided by Friedhelm Kuehn.
>
> Modified:
> tomcat/trunk/java/javax/el/BeanELResolver.java
> tomcat/trunk/webapps/docs/changelog.xml
> private static final Method getMethod(Class<?> type, Method m) {
> - if (m == null || Modifier.isPublic(type.getModifiers())) {
> + if (m == null || Modifier.isPublic(m.getModifiers())) {
I think the old code is the correct one.
See that below that in BeanELResolver.getMethod() we call
Class..getMethod(...) which returns only public methods.
If I understand it correctly BeanELResolver.getMethod() checks that
- either the class declaring the method is public, or
- the method is a public one declared in a public parent or public
interface implemented by this class.
Best regards,
Konstantin Kolinko
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]