Class AnnotationMappingProxy<T extends Annotation>
java.lang.Object
org.miaixz.bus.core.lang.annotation.resolve.AnnotationMappingProxy<T>
- Type Parameters:
T- 注解类型
- All Implemented Interfaces:
InvocationHandler
public final class AnnotationMappingProxy<T extends Annotation>
extends Object
implements InvocationHandler
代理注解处理器,用于为
AnnotationMapping生成代理对象,当从该代理对象上获取属性值时,
总是通过AnnotationMapping.getResolvedAttributeValue(String, Class)获取。- Since:
- Java 17+
- Author:
- Kimi Liu
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic <A extends Annotation>
Acreate(Class<? extends A> annotationType, AnnotationMapping<A> mapping) 创建一个代理对象调用被代理的方法static booleanisProxied(Annotation annotation) 当前注解是否由当前代理类生成
-
Method Details
-
create
public static <A extends Annotation> A create(Class<? extends A> annotationType, AnnotationMapping<A> mapping) 创建一个代理对象- Type Parameters:
A- 注解类型- Parameters:
annotationType- 注解类型mapping- 注解映射对象- Returns:
- 代理对象
-
isProxied
当前注解是否由当前代理类生成- Parameters:
annotation- 注解对象- Returns:
- 是否
-
invoke
调用被代理的方法- Specified by:
invokein interfaceInvocationHandler- Parameters:
proxy- 代理对象method- 方法args- 参数- Returns:
- 返回值
-