public interface MethodConfig extends DeclarationConfig
Enhancement
Modifier and Type | Method and Description |
---|---|
MethodConfig |
addAnnotation(java.lang.annotation.Annotation annotation)
Adds given annotation to this method.
|
MethodConfig |
addAnnotation(AnnotationInfo annotation)
Adds given annotation to this method.
|
MethodConfig |
addAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
Adds a marker annotation of given type to this method.
|
MethodInfo |
info()
Returns the
MethodInfo corresponding to this transformed method. |
java.util.List<ParameterConfig> |
parameters()
Returns a list of
ParameterConfig objects for each parameter of this method. |
MethodConfig |
removeAllAnnotations()
Removes all annotations from this method.
|
MethodConfig |
removeAnnotation(java.util.function.Predicate<AnnotationInfo> predicate)
Removes all annotations matching given predicate from this method.
|
MethodInfo info()
MethodInfo
corresponding to this transformed method.info
in interface DeclarationConfig
MethodInfo
corresponding to this transformed method, never null
MethodConfig addAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
addAnnotation
in interface DeclarationConfig
annotationType
- the annotation type, must not be null
MethodConfig 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 method, must not be null
MethodConfig addAnnotation(java.lang.annotation.Annotation annotation)
AnnotationLiteral
.addAnnotation
in interface DeclarationConfig
annotation
- the annotation to add to this method, must not be null
MethodConfig removeAnnotation(java.util.function.Predicate<AnnotationInfo> predicate)
removeAnnotation
in interface DeclarationConfig
predicate
- an annotation predicate, must not be null
MethodConfig removeAllAnnotations()
removeAllAnnotations
in interface DeclarationConfig
java.util.List<ParameterConfig> parameters()
ParameterConfig
objects for each parameter of this method.ParameterConfig
objects, never null