public interface FieldConfig extends DeclarationConfig
Enhancement
Modifier and Type | Method and Description |
---|---|
FieldConfig |
addAnnotation(java.lang.annotation.Annotation annotation)
Adds given annotation to this field.
|
FieldConfig |
addAnnotation(AnnotationInfo annotation)
Adds given annotation to this field.
|
FieldConfig |
addAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
Adds a marker annotation of given type to this field.
|
FieldInfo |
info()
Returns the
FieldInfo corresponding to this transformed field. |
FieldConfig |
removeAllAnnotations()
Removes all annotations from this field.
|
FieldConfig |
removeAnnotation(java.util.function.Predicate<AnnotationInfo> predicate)
Removes all annotations matching given predicate from this field.
|
FieldInfo info()
FieldInfo
corresponding to this transformed field.info
in interface DeclarationConfig
FieldInfo
corresponding to this transformed field, never null
FieldConfig addAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
addAnnotation
in interface DeclarationConfig
annotationType
- the annotation type, must not be null
FieldConfig addAnnotation(AnnotationInfo annotation)
AnnotationInfo
can be obtained
from an annotation target, or constructed from scratch using AnnotationBuilder
.addAnnotation
in interface DeclarationConfig
annotation
- the annotation to add to this field, must not be null
FieldConfig addAnnotation(java.lang.annotation.Annotation annotation)
AnnotationLiteral
.addAnnotation
in interface DeclarationConfig
annotation
- the annotation to add to this field, must not be null
FieldConfig removeAnnotation(java.util.function.Predicate<AnnotationInfo> predicate)
removeAnnotation
in interface DeclarationConfig
predicate
- an annotation predicate, must not be null
FieldConfig removeAllAnnotations()
removeAllAnnotations
in interface DeclarationConfig