protected class Advice.MethodSizeHandler.Default.ForAdvice extends Object implements Advice.MethodSizeHandler.ForAdvice
Advice.MethodSizeHandler.Default, Advice.MethodSizeHandler.ForAdvice, Advice.MethodSizeHandler.ForInstrumentedMethod, Advice.MethodSizeHandler.NoOp
UNDEFINED_SIZE
Modifier | Constructor and Description |
---|---|
protected |
ForAdvice(MethodDescription.InDefinedShape adviceMethod,
List<? extends TypeDescription> startTypes,
List<? extends TypeDescription> endTypes)
Creates a new method size handler for an advice method.
|
Modifier and Type | Method and Description |
---|---|
void |
recordMaxima(int stackSize,
int localVariableLength)
Records the maximum values for stack size and local variable array which are required by the advice method
for its individual execution without translation.
|
void |
recordPadding(int padding)
Records a minimum padding additionally to the computed stack size that is required for implementing this advice method.
|
void |
requireLocalVariableLength(int localVariableLength)
Requires a minimum length of the local variable array.
|
void |
requireStackSize(int stackSize)
Records a minimum stack size required by the represented advice method.
|
protected ForAdvice(MethodDescription.InDefinedShape adviceMethod, List<? extends TypeDescription> startTypes, List<? extends TypeDescription> endTypes)
adviceMethod
- The advice method.startTypes
- The types provided before execution of the advice code.endTypes
- The types provided after execution of the advice code.public void requireLocalVariableLength(int localVariableLength)
Advice.MethodSizeHandler
requireLocalVariableLength
in interface Advice.MethodSizeHandler
localVariableLength
- The minimal required length of the local variable array.public void requireStackSize(int stackSize)
Advice.MethodSizeHandler
requireStackSize
in interface Advice.MethodSizeHandler
stackSize
- The minimum size required by the represented advice method.public void recordMaxima(int stackSize, int localVariableLength)
Advice.MethodSizeHandler.ForAdvice
recordMaxima
in interface Advice.MethodSizeHandler.ForAdvice
stackSize
- The minimum required stack size.localVariableLength
- The minimum required length of the local variable array.public void recordPadding(int padding)
Advice.MethodSizeHandler.ForAdvice
recordPadding
in interface Advice.MethodSizeHandler.ForAdvice
padding
- The minimum required padding.Copyright © 2014–2018. All rights reserved.