Package net.bytebuddy.asm
Class Advice.Dispatcher.RelocationHandler.ForType.Bound
java.lang.Object
net.bytebuddy.asm.Advice.Dispatcher.RelocationHandler.ForType.Bound
- All Implemented Interfaces:
Advice.Dispatcher.RelocationHandler.Bound
- Enclosing class:
- Advice.Dispatcher.RelocationHandler.ForType
@Enhance(includeSyntheticFields=true)
protected class Advice.Dispatcher.RelocationHandler.ForType.Bound
extends Object
implements Advice.Dispatcher.RelocationHandler.Bound
A bound relocation handler for
Advice.Dispatcher.RelocationHandler.ForType
.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final MethodDescription
The instrumented method.private final Advice.Dispatcher.RelocationHandler.Relocation
The relocation to use.Fields inherited from interface net.bytebuddy.asm.Advice.Dispatcher.RelocationHandler.Bound
NO_REQUIRED_SIZE
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
Bound
(MethodDescription instrumentedMethod, Advice.Dispatcher.RelocationHandler.Relocation relocation) Creates a new bound relocation handler. -
Method Summary
Modifier and TypeMethodDescriptionint
apply
(org.objectweb.asm.MethodVisitor methodVisitor, int offset) Applies this relocation handler.
-
Field Details
-
instrumentedMethod
The instrumented method. -
relocation
The relocation to use.
-
-
Constructor Details
-
Bound
protected Bound(MethodDescription instrumentedMethod, Advice.Dispatcher.RelocationHandler.Relocation relocation) Creates a new bound relocation handler.- Parameters:
instrumentedMethod
- The instrumented method.relocation
- The relocation to apply.
-
-
Method Details
-
apply
public int apply(org.objectweb.asm.MethodVisitor methodVisitor, int offset) Applies this relocation handler.- Specified by:
apply
in interfaceAdvice.Dispatcher.RelocationHandler.Bound
- Parameters:
methodVisitor
- The method visitor to use.offset
- The offset of the relevant value.- Returns:
- The minimal required stack size to apply this relocation handler.
-