AnnotationUtils.getAnnotationAttributes makes Method accessible (analogous to AnnotationUtils.getValue)

Issue: SPR-12858
This commit is contained in:
Juergen Hoeller 2015-03-31 10:28:42 +02:00
parent 14c891c3b3
commit 1d33fd039a
1 changed files with 1 additions and 0 deletions

View File

@ -583,6 +583,7 @@ public abstract class AnnotationUtils {
for (Method method : methods) {
if (method.getParameterTypes().length == 0 && method.getReturnType() != void.class) {
try {
ReflectionUtils.makeAccessible(method);
Object value = method.invoke(annotation);
attrs.put(method.getName(), adaptValue(value, classValuesAsString, nestedAnnotationsAsMap));
}