public final class AnnotatedField extends AnnotatedMember
| 限定符和类型 | 字段和说明 |
|---|---|
protected Field |
_field |
_annotations| 构造器和说明 |
|---|
AnnotatedField(Field field,
AnnotationMap annMap) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
addOrOverride(Annotation a)
Method called to override an annotation, usually due to a mix-in
annotation masking or overriding an annotation 'real' constructor
has.
|
Field |
getAnnotated()
Method that can be used to find actual JDK element that this instance
represents.
|
<A extends Annotation> |
getAnnotation(Class<A> acls) |
int |
getAnnotationCount() |
Class<?> |
getDeclaringClass() |
String |
getFullName() |
Type |
getGenericType()
Full generic type of the annotated element; definition
of what exactly this means depends on sub-class.
|
Member |
getMember() |
int |
getModifiers() |
String |
getName() |
Class<?> |
getRawType()
"Raw" type (type-erased class) of the annotated element; definition
of what exactly this means depends on sub-class.
|
void |
setValue(Object pojo,
Object value)
Optional method that can be used to assign value of
this member on given object, if this is a supported
operation for member type.
|
String |
toString() |
AnnotatedField |
withAnnotations(AnnotationMap ann)
Fluent factory method that will construct a new instance that uses specified
instance annotations instead of currently configured ones.
|
fixAccess, getAllAnnotationsgetType, hasAnnotation, isPublic, withFallBackAnnotationsFromprotected final Field _field
public AnnotatedField(Field field, AnnotationMap annMap)
public AnnotatedField withAnnotations(AnnotationMap ann)
AnnotatedwithAnnotations 在类中 Annotatedpublic void addOrOverride(Annotation a)
public Field getAnnotated()
AnnotatedgetAnnotated 在类中 Annotatedpublic int getModifiers()
getModifiers 在类中 Annotatedpublic <A extends Annotation> A getAnnotation(Class<A> acls)
getAnnotation 在类中 Annotatedpublic Type getGenericType()
AnnotatedgetGenericType 在类中 Annotatedpublic Class<?> getRawType()
AnnotatedgetRawType 在类中 Annotatedpublic Class<?> getDeclaringClass()
getDeclaringClass 在类中 AnnotatedMemberpublic Member getMember()
getMember 在类中 AnnotatedMemberpublic void setValue(Object pojo, Object value) throws IllegalArgumentException
AnnotatedMemberThis is implemented for fiedlds and single-argument methods; but not for constructor parameters or other types of methods.
setValue 在类中 AnnotatedMemberIllegalArgumentExceptionpublic String getFullName()
public int getAnnotationCount()