@HashCodeAndEqualsPlugin.Enhance public static class MemberSubstitution.Substitution.ForValue extends Object implements MemberSubstitution.Substitution, MemberSubstitution.Substitution.Factory
MemberSubstitution.Substitution.Chain, MemberSubstitution.Substitution.Factory, MemberSubstitution.Substitution.ForFieldAccess, MemberSubstitution.Substitution.ForMethodInvocation, MemberSubstitution.Substitution.ForValue, MemberSubstitution.Substitution.Stubbing| Constructor and Description |
|---|
ForValue(StackManipulation stackManipulation,
TypeDescription.Generic typeDescription)
Creates a new substitution for loading a constant value.
|
| Modifier and Type | Method and Description |
|---|---|
MemberSubstitution.Substitution |
make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
TypePool typePool)
Creates a substitution for an instrumented method.
|
StackManipulation |
resolve(TypeDescription targetType,
ByteCodeElement target,
TypeList.Generic parameters,
TypeDescription.Generic result,
StackManipulation original,
int freeOffset)
Resolves this substitution into a stack manipulation.
|
public ForValue(StackManipulation stackManipulation, TypeDescription.Generic typeDescription)
stackManipulation - The stack manipulation to load the value that represents the substitution.typeDescription - The type of the represented stack manipulation.public MemberSubstitution.Substitution make(TypeDescription instrumentedType, MethodDescription instrumentedMethod, TypePool typePool)
make in interface MemberSubstitution.Substitution.FactoryinstrumentedType - The instrumented type.instrumentedMethod - The instrumented method.typePool - The type pool being used.public StackManipulation resolve(TypeDescription targetType, ByteCodeElement target, TypeList.Generic parameters, TypeDescription.Generic result, StackManipulation original, int freeOffset)
resolve in interface MemberSubstitution.SubstitutiontargetType - The target type on which a member is accessed.target - The target field, method or constructor that is substituted.parameters - All parameters that serve as input to this access.result - The result that is expected from the interaction or void if no result is expected.original - The original byte code expression that is being executed.freeOffset - The first free offset of the local variable array that can be used for storing values.Copyright © 2014–2023. All rights reserved.