public static class MemberAttributeExtension.ForMethod extends MemberAttributeExtension<MethodAttributeAppender.Factory> implements AsmVisitorWrapper.ForDeclaredMethods.MethodVisitorWrapper
MemberAttributeExtension.ForField, MemberAttributeExtension.ForMethodannotationValueFilterFactory, attributeAppenderFactory| Modifier | Constructor and Description | 
|---|---|
|   | ForMethod()Creates a method attribute extension. | 
|   | ForMethod(AnnotationValueFilter.Factory annotationValueFilterFactory)Creates a method attribute extension. | 
| protected  | ForMethod(AnnotationValueFilter.Factory annotationValueFilterFactory,
         MethodAttributeAppender.Factory attributeAppenderFactory)Creates a method attribute extension. | 
| Modifier and Type | Method and Description | 
|---|---|
| MemberAttributeExtension.ForMethod | annotateMethod(Annotation... annotation)Appends the supplied annotations. | 
| MemberAttributeExtension.ForMethod | annotateMethod(AnnotationDescription... annotation)Appends the supplied annotations. | 
| MemberAttributeExtension.ForMethod | annotateMethod(Collection<? extends AnnotationDescription> annotations)Appends the supplied annotations. | 
| MemberAttributeExtension.ForMethod | annotateMethod(List<? extends Annotation> annotations)Appends the supplied annotations. | 
| MemberAttributeExtension.ForMethod | annotateParameter(int index,
                 Annotation... annotation)Appends the supplied annotations to the parameter at the given index. | 
| MemberAttributeExtension.ForMethod | annotateParameter(int index,
                 AnnotationDescription... annotation)Appends the supplied annotations to the parameter at the given index. | 
| MemberAttributeExtension.ForMethod | annotateParameter(int index,
                 Collection<? extends AnnotationDescription> annotations)Appends the supplied annotations to the parameter at the given index. | 
| MemberAttributeExtension.ForMethod | annotateParameter(int index,
                 List<? extends Annotation> annotations)Appends the supplied annotations to the parameter at the given index. | 
| MemberAttributeExtension.ForMethod | attribute(MethodAttributeAppender.Factory attributeAppenderFactory)Appends the supplied method attribute appender factory. | 
| AsmVisitorWrapper | on(ElementMatcher<? super MethodDescription> matcher)Applies this attribute extension on any method or constructor that matches the supplied matcher. | 
| org.objectweb.asm.MethodVisitor | wrap(TypeDescription instrumentedType,
    MethodDescription instrumentedMethod,
    org.objectweb.asm.MethodVisitor methodVisitor,
    Implementation.Context implementationContext,
    TypePool typePool,
    int writerFlags,
    int readerFlags)Wraps a method visitor. | 
public ForMethod()
public ForMethod(AnnotationValueFilter.Factory annotationValueFilterFactory)
annotationValueFilterFactory - The annotation value filter factory to apply.protected ForMethod(AnnotationValueFilter.Factory annotationValueFilterFactory, MethodAttributeAppender.Factory attributeAppenderFactory)
annotationValueFilterFactory - The annotation value filter factory to apply.attributeAppenderFactory - The method attribute appender factory to use.public MemberAttributeExtension.ForMethod annotateMethod(Annotation... annotation)
annotation - The annotations to append.public MemberAttributeExtension.ForMethod annotateMethod(List<? extends Annotation> annotations)
annotations - The annotations to append.public MemberAttributeExtension.ForMethod annotateMethod(AnnotationDescription... annotation)
annotation - The annotations to append.public MemberAttributeExtension.ForMethod annotateMethod(Collection<? extends AnnotationDescription> annotations)
annotations - The annotations to append.public MemberAttributeExtension.ForMethod annotateParameter(int index, Annotation... annotation)
index - The parameter index.annotation - The annotations to append.public MemberAttributeExtension.ForMethod annotateParameter(int index, List<? extends Annotation> annotations)
index - The parameter index.annotations - The annotations to append.public MemberAttributeExtension.ForMethod annotateParameter(int index, AnnotationDescription... annotation)
index - The parameter index.annotation - The annotations to append.public MemberAttributeExtension.ForMethod annotateParameter(int index, Collection<? extends AnnotationDescription> annotations)
index - The parameter index.annotations - The annotations to append.public MemberAttributeExtension.ForMethod attribute(MethodAttributeAppender.Factory attributeAppenderFactory)
attributeAppenderFactory - The attribute appender factory to append.public org.objectweb.asm.MethodVisitor wrap(TypeDescription instrumentedType, MethodDescription instrumentedMethod, org.objectweb.asm.MethodVisitor methodVisitor, Implementation.Context implementationContext, TypePool typePool, int writerFlags, int readerFlags)
wrap in interface AsmVisitorWrapper.ForDeclaredMethods.MethodVisitorWrapperinstrumentedType - The instrumented type.instrumentedMethod - The method that is currently being defined.methodVisitor - The original field visitor that defines the given method.implementationContext - The implementation context to use.typePool - The type pool to use.writerFlags - The ASM ClassWriter reader flags to consider.readerFlags - The ASM ClassReader reader flags to consider.public AsmVisitorWrapper on(ElementMatcher<? super MethodDescription> matcher)
matcher - The matcher that decides what methods or constructors the represented extension is applied to.Copyright © 2014–2021. All rights reserved.