private static class TypePool.Default.LazyTypeDescription.LazyAnnotationDescription extends AnnotationDescription.AbstractBase
Modifier and Type | Class and Description |
---|---|
private static class |
TypePool.Default.LazyTypeDescription.LazyAnnotationDescription.Loadable<S extends java.lang.annotation.Annotation>
A loadable version of a lazy annotation description.
|
AnnotationDescription.AbstractBase.ForPrepared<S extends java.lang.annotation.Annotation>
AnnotationDescription.AbstractBase, AnnotationDescription.AnnotationInvocationHandler<T extends java.lang.annotation.Annotation>, AnnotationDescription.Builder, AnnotationDescription.ForLoadedAnnotation<S extends java.lang.annotation.Annotation>, AnnotationDescription.Latent
Modifier and Type | Field and Description |
---|---|
private TypeDescription |
annotationType
The type of this annotation.
|
protected TypePool |
typePool
The type pool for looking up type references.
|
protected java.util.Map<java.lang.String,AnnotationValue<?,?>> |
values
A map of annotation values by their property name.
|
UNDEFINED
Modifier | Constructor and Description |
---|---|
private |
LazyAnnotationDescription(TypePool typePool,
TypeDescription annotationType,
java.util.Map<java.lang.String,AnnotationValue<?,?>> values)
Creates a new lazy annotation description.
|
Modifier and Type | Method and Description |
---|---|
protected static AnnotationList |
asList(TypePool typePool,
java.util.List<? extends TypePool.Default.LazyTypeDescription.AnnotationToken> tokens)
Represents a list of annotation tokens in form of a list of lazy type annotations.
|
protected static AnnotationList |
asListOfNullable(TypePool typePool,
java.util.List<? extends TypePool.Default.LazyTypeDescription.AnnotationToken> tokens)
Represents a list of annotation tokens in form of a list of lazy type annotations.
|
TypeDescription |
getAnnotationType()
Returns a description of the annotation type of this annotation.
|
AnnotationValue<?,?> |
getValue(MethodDescription.InDefinedShape property)
Returns the value of this annotation.
|
<T extends java.lang.annotation.Annotation> |
prepare(java.lang.Class<T> annotationType)
Links this annotation description to a given annotation type such that it can be loaded.
|
equals, getElementTypes, getRetention, hashCode, isDocumented, isInherited, toString
protected final TypePool typePool
private final TypeDescription annotationType
protected final java.util.Map<java.lang.String,AnnotationValue<?,?>> values
private LazyAnnotationDescription(TypePool typePool, TypeDescription annotationType, java.util.Map<java.lang.String,AnnotationValue<?,?>> values)
typePool
- The type pool to be used for looking up linked types.annotationType
- The annotation's type.values
- A map of annotation value names to their value representations.protected static AnnotationList asListOfNullable(TypePool typePool, java.util.List<? extends TypePool.Default.LazyTypeDescription.AnnotationToken> tokens)
tokens
are null
, an empty list is returned.typePool
- The type pool to be used for looking up linked types.tokens
- The tokens to represent in the list.protected static AnnotationList asList(TypePool typePool, java.util.List<? extends TypePool.Default.LazyTypeDescription.AnnotationToken> tokens)
typePool
- The type pool to be used for looking up linked types.tokens
- The tokens to represent in the list.public AnnotationValue<?,?> getValue(MethodDescription.InDefinedShape property)
property
- The property being accessed.public TypeDescription getAnnotationType()
public <T extends java.lang.annotation.Annotation> TypePool.Default.LazyTypeDescription.LazyAnnotationDescription.Loadable<T> prepare(java.lang.Class<T> annotationType)
T
- The type of the annotation.annotationType
- The loaded annotation type of this annotation description.