T - The type of the handled annotation.public static class AnnotationDescription.AnnotationInvocationHandler<T extends Annotation> extends Object implements InvocationHandler
InvocationHandler for implementing annotations.| Modifier | Constructor and Description |
|---|---|
protected |
AnnotationInvocationHandler(Class<T> annotationType,
LinkedHashMap<Method,AnnotationValue.Loaded<?>> values)
Creates a new invocation handler.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object other) |
int |
hashCode() |
Object |
invoke(Object proxy,
Method method,
Object[] argument) |
static <S extends Annotation> |
of(ClassLoader classLoader,
Class<S> annotationType,
Map<String,? extends AnnotationValue<?,?>> values)
Creates a proxy instance for the supplied annotation type and values.
|
protected String |
toStringRepresentation()
Returns the string representation of the represented annotation.
|
protected AnnotationInvocationHandler(Class<T> annotationType, LinkedHashMap<Method,AnnotationValue.Loaded<?>> values)
annotationType - The loaded annotation type.values - A sorted list of values of this annotation.public static <S extends Annotation> S of(@MaybeNull ClassLoader classLoader, Class<S> annotationType, Map<String,? extends AnnotationValue<?,?>> values)
S - The type of the handled annotation.classLoader - The class loader that should be used for loading the annotation's values.annotationType - The annotation's type.values - The values that the annotation contains.public Object invoke(Object proxy, Method method, @MaybeNull Object[] argument)
invoke in interface InvocationHandlerprotected String toStringRepresentation()
@CachedReturnPlugin.Enhance(value="hashCode") public int hashCode()
public boolean equals(@MaybeNull Object other)
Copyright © 2014–2025. All rights reserved.