T
- The represented value's unloaded type.S
- The represented value's loaded type.public interface AnnotationValue<T,S>
String
s or arrays of primitive types or strings.TypeDescription
or an array of such a descriptions.EnumerationDescription
or an array of such a description.AnnotationDescription
or an array of such a description.Modifier and Type | Interface and Description |
---|---|
static class |
AnnotationValue.AbstractBase<U,V>
An abstract base implementation of an unloaded annotation value.
|
static class |
AnnotationValue.ForAnnotationDescription<U extends Annotation>
A description of an
Annotation as a value of another annotation. |
static class |
AnnotationValue.ForConstant<U>
Represents a primitive value, a
String or an array of the latter types. |
static class |
AnnotationValue.ForDescriptionArray<U,V>
Describes a complex array that is the value of an annotation.
|
static class |
AnnotationValue.ForEnumerationDescription<U extends Enum<U>>
A description of an
Enum as a value of an annotation. |
static class |
AnnotationValue.ForTypeDescription<U extends Class<U>>
A description of a
Class as a value of an annotation. |
static interface |
AnnotationValue.Loaded<U>
A loaded variant of an
AnnotationValue . |
static class |
AnnotationValue.RenderingDispatcher
A rendering dispatcher is responsible for resolving annotation values to
String representations. |
Modifier and Type | Field and Description |
---|---|
static AnnotationValue<?,?> |
UNDEFINED
An undefined annotation value.
|
Modifier and Type | Method and Description |
---|---|
AnnotationValue.Loaded<S> |
load(ClassLoader classLoader)
Returns the loaded value of this annotation.
|
AnnotationValue.Loaded<S> |
loadSilent(ClassLoader classLoader)
Returns the loaded value of this annotation without throwing a checked exception.
|
T |
resolve()
Resolves the unloaded value of this annotation.
|
<W> W |
resolve(Class<? extends W> type)
Resolves the unloaded value of this annotation.
|
static final AnnotationValue<?,?> UNDEFINED
T resolve()
<W> W resolve(Class<? extends W> type)
W
- The annotation value's unloaded type.type
- The annotation value's unloaded type.AnnotationValue.Loaded<S> load(ClassLoader classLoader) throws ClassNotFoundException
classLoader
- The class loader for loading this value.ClassNotFoundException
- If a type that represents a loaded value cannot be found.AnnotationValue.Loaded<S> loadSilent(ClassLoader classLoader)
classLoader
- The class loader for loading this value.Copyright © 2014–2019. All rights reserved.