Package io.github.resilience4j.utils
Class AnnotationExtractor
- java.lang.Object
-
- io.github.resilience4j.utils.AnnotationExtractor
-
public class AnnotationExtractor extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T extends java.lang.annotation.Annotation>
Textract(java.lang.Class<?> targetClass, java.lang.Class<T> annotationClass)extract annotation from target classstatic <T extends java.lang.annotation.Annotation>
TextractAnnotationFromProxy(java.lang.Object targetProxy, java.lang.Class<T> annotationClass)Extracts the annotation from the target implementation of the Proxy(ies)
-
-
-
Method Detail
-
extract
@Nullable public static <T extends java.lang.annotation.Annotation> T extract(java.lang.Class<?> targetClass, java.lang.Class<T> annotationClass)extract annotation from target class- Type Parameters:
T- The annotation type.- Parameters:
targetClass- target classannotationClass- annotation class- Returns:
- annotation
-
extractAnnotationFromProxy
@Nullable public static <T extends java.lang.annotation.Annotation> T extractAnnotationFromProxy(java.lang.Object targetProxy, java.lang.Class<T> annotationClass)Extracts the annotation from the target implementation of the Proxy(ies)- Type Parameters:
T-- Parameters:
targetProxy- The proxy classannotationClass- The annotation to extract- Returns:
-
-