Package net.bytebuddy.asm
Class MemberSubstitution.Substitution.ForMethodInvocation.OfGivenMethod
- java.lang.Object
-
- net.bytebuddy.asm.MemberSubstitution.Substitution.ForMethodInvocation.OfGivenMethod
-
- All Implemented Interfaces:
MemberSubstitution.Substitution.Factory
- Enclosing class:
- MemberSubstitution.Substitution.ForMethodInvocation
@Enhance public static class MemberSubstitution.Substitution.ForMethodInvocation.OfGivenMethod extends java.lang.Object implements MemberSubstitution.Substitution.Factory
A factory for a substitution that invokes a given method.
-
-
Field Summary
Fields Modifier and Type Field Description private MethodDescription
methodDescription
The method to invoke.
-
Constructor Summary
Constructors Constructor Description OfGivenMethod(MethodDescription methodDescription)
Creates a new factory for a substitution that invokes a given method.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MemberSubstitution.Substitution
make(TypeDescription instrumentedType, MethodDescription instrumentedMethod, TypePool typePool)
Creates a substitution for an instrumented method.
-
-
-
Field Detail
-
methodDescription
private final MethodDescription methodDescription
The method to invoke.
-
-
Constructor Detail
-
OfGivenMethod
public OfGivenMethod(MethodDescription methodDescription)
Creates a new factory for a substitution that invokes a given method.- Parameters:
methodDescription
- The method to invoke.
-
-
Method Detail
-
make
public MemberSubstitution.Substitution make(TypeDescription instrumentedType, MethodDescription instrumentedMethod, TypePool typePool)
Creates a substitution for an instrumented method.- Specified by:
make
in interfaceMemberSubstitution.Substitution.Factory
- Parameters:
instrumentedType
- The instrumented type.instrumentedMethod
- The instrumented method.typePool
- The type pool being used.- Returns:
- The substitution to apply within the instrumented method.
-
-