Package net.bytebuddy.asm
Class MemberSubstitution.Substitution.Resolver.MethodInvoking
- java.lang.Object
-
- net.bytebuddy.asm.MemberSubstitution.Substitution.Resolver.MethodInvoking
-
- All Implemented Interfaces:
MemberSubstitution.Substitution.Resolver
- Enclosing interface:
- MemberSubstitution.Substitution.Resolver
public static class MemberSubstitution.Substitution.Resolver.MethodInvoking extends java.lang.Object implements MemberSubstitution.Substitution.Resolver
A resolver that invokes a method.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.asm.MemberSubstitution.Substitution.Resolver
MemberSubstitution.Substitution.Resolver.FieldAccessing, MemberSubstitution.Substitution.Resolver.MethodInvoking, MemberSubstitution.Substitution.Resolver.Stubbing, MemberSubstitution.Substitution.Resolver.Unresolved
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
MethodInvoking(MethodDescription methodDescription)
Creates a resolver for a method invocation.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StackManipulation
apply(TypeDescription instrumentedType, ByteCodeElement target, TypeList.Generic arguments, TypeDescription.Generic result)
Applies this resolver.boolean
isResolved()
Checks if this resolver was actually resolved, i.e.
-
-
-
Constructor Detail
-
MethodInvoking
protected MethodInvoking(MethodDescription methodDescription)
Creates a resolver for a method invocation.- Parameters:
methodDescription
- The method that is used for substitution.
-
-
Method Detail
-
isResolved
public boolean isResolved()
Description copied from interface:MemberSubstitution.Substitution.Resolver
Checks if this resolver was actually resolved, i.e. if a member should be substituted at all.- Specified by:
isResolved
in interfaceMemberSubstitution.Substitution.Resolver
- Returns:
true
if a found member should be substituted.
-
apply
public StackManipulation apply(TypeDescription instrumentedType, ByteCodeElement target, TypeList.Generic arguments, TypeDescription.Generic result)
Description copied from interface:MemberSubstitution.Substitution.Resolver
Applies this resolver. This is only legal for resolved resolvers.- Specified by:
apply
in interfaceMemberSubstitution.Substitution.Resolver
- Parameters:
instrumentedType
- The instrumented type.target
- The substituted byte code element.arguments
- The factual arguments to the byte code element.result
- The expected result type orvoid
if no result is expected.- Returns:
- A stack manipulation that applies the resolved byte code representing the substitution.
-
-