Polishing
This commit is contained in:
parent
21cfa0e4ba
commit
2caaa81afa
|
@ -454,7 +454,7 @@ public abstract class AnnotationUtils {
|
|||
* or if it should be looked up via @{@link java.lang.annotation.Repeatable}
|
||||
* when running on Java 8 or higher
|
||||
* @param declaredMode {@code true} if only declared annotations (i.e.,
|
||||
* directly or indirectly present) should be considered.
|
||||
* directly or indirectly present) should be considered
|
||||
* @return the annotations found or an empty set; never {@code null}
|
||||
* @since 4.2
|
||||
* @see org.springframework.core.BridgeMethodResolver#findBridgedMethod
|
||||
|
@ -1277,10 +1277,8 @@ public abstract class AnnotationUtils {
|
|||
DefaultAnnotationAttributeExtractor attributeExtractor =
|
||||
new DefaultAnnotationAttributeExtractor(annotation, annotatedElement);
|
||||
InvocationHandler handler = new SynthesizedAnnotationInvocationHandler(attributeExtractor);
|
||||
A synthesizedAnnotation = (A) Proxy.newProxyInstance(ClassUtils.getDefaultClassLoader(),
|
||||
return (A) Proxy.newProxyInstance(ClassUtils.getDefaultClassLoader(),
|
||||
new Class<?>[] {(Class<A>) annotationType, SynthesizedAnnotation.class}, handler);
|
||||
|
||||
return synthesizedAnnotation;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1325,10 +1323,8 @@ public abstract class AnnotationUtils {
|
|||
MapAnnotationAttributeExtractor attributeExtractor =
|
||||
new MapAnnotationAttributeExtractor(attributes, annotationType, annotatedElement);
|
||||
InvocationHandler handler = new SynthesizedAnnotationInvocationHandler(attributeExtractor);
|
||||
A synthesizedAnnotation = (A) Proxy.newProxyInstance(ClassUtils.getDefaultClassLoader(),
|
||||
return (A) Proxy.newProxyInstance(ClassUtils.getDefaultClassLoader(),
|
||||
new Class<?>[] {annotationType, SynthesizedAnnotation.class}, handler);
|
||||
|
||||
return synthesizedAnnotation;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue