This content has been marked as final.
Show 2 replies
-
1. Re: AnnotatedElementMetaDataLoader doesn't work for private
alesj Aug 8, 2008 5:05 AM (in response to wolfc)Which MDR version is this?
Since this looks OK in MDR trunk:else if (signature instanceof MethodSignature) { MethodSignature methodSignature = (MethodSignature) signature; Method method = methodSignature.getMethod(); if (method == null) method = ReflectionUtils.findMethod(clazz, signature.getName(), signature.getParametersTypes(clazz));
Where RU.findMethod ispublic static Method findMethod(Class<?> clazz, String name, Class<?>... parameterTypes) { if (clazz == null) return null; try { return clazz.getDeclaredMethod(name, parameterTypes); } catch(Exception ignored) { } return findMethod(clazz.getSuperclass(), name, parameterTypes); }
Looking up declared methods, means it includes private as well. ;-)"wolfc" wrote:
Dare I say, I consider this a bug.
I see you're the same as vickyk:
- http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4168997#4168997
;-) -
2. Re: AnnotatedElementMetaDataLoader doesn't work for private
wolfc Aug 8, 2008 5:27 AM (in response to wolfc)At least I'm right about the part where it is considered a bug. :-P
https://jira.jboss.org/jira/browse/JBMDR-29