@HashCodeAndEqualsPlugin.Enhance public static class MemberSubstitution.Substitution.ForMethodInvocation.OfMatchedMethod extends java.lang.Object implements MemberSubstitution.Substitution.Factory
Modifier and Type | Field and Description |
---|---|
private ElementMatcher<? super MethodDescription> |
matcher
The matcher for locating the method to substitute with.
|
private MethodGraph.Compiler |
methodGraphCompiler
The method graph compiler to use.
|
Constructor and Description |
---|
OfMatchedMethod(ElementMatcher<? super MethodDescription> matcher,
MethodGraph.Compiler methodGraphCompiler)
Creates a factory for a substitution that locates a method on the receiver type.
|
Modifier and Type | Method and Description |
---|---|
MemberSubstitution.Substitution |
make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
TypePool typePool)
Creates a substitution for an instrumented method.
|
private final ElementMatcher<? super MethodDescription> matcher
private final MethodGraph.Compiler methodGraphCompiler
public OfMatchedMethod(ElementMatcher<? super MethodDescription> matcher, MethodGraph.Compiler methodGraphCompiler)
matcher
- The matcher for locating the method to substitute with.methodGraphCompiler
- The method graph compiler to use.public MemberSubstitution.Substitution make(TypeDescription instrumentedType, MethodDescription instrumentedMethod, TypePool typePool)
make
in interface MemberSubstitution.Substitution.Factory
instrumentedType
- The instrumented type.instrumentedMethod
- The instrumented method.typePool
- The type pool being used.