Package net.bytebuddy.asm
Enum Advice.MethodSizeHandler.NoOp
- java.lang.Object
-
- java.lang.Enum<Advice.MethodSizeHandler.NoOp>
-
- net.bytebuddy.asm.Advice.MethodSizeHandler.NoOp
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<Advice.MethodSizeHandler.NoOp>,Advice.MethodSizeHandler,Advice.MethodSizeHandler.ForAdvice,Advice.MethodSizeHandler.ForInstrumentedMethod
- Enclosing interface:
- Advice.MethodSizeHandler
public static enum Advice.MethodSizeHandler.NoOp extends java.lang.Enum<Advice.MethodSizeHandler.NoOp> implements Advice.MethodSizeHandler.ForInstrumentedMethod, Advice.MethodSizeHandler.ForAdvice
A non-operational method size handler.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.asm.Advice.MethodSizeHandler
Advice.MethodSizeHandler.Default, Advice.MethodSizeHandler.ForAdvice, Advice.MethodSizeHandler.ForInstrumentedMethod, Advice.MethodSizeHandler.NoOp
-
-
Enum Constant Summary
Enum Constants Enum Constant Description INSTANCEThe singleton instance.
-
Field Summary
-
Fields inherited from interface net.bytebuddy.asm.Advice.MethodSizeHandler
UNDEFINED_SIZE
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Advice.MethodSizeHandler.ForAdvicebindEnter(MethodDescription.InDefinedShape adviceMethod)Binds a method size handler for the enter advice.Advice.MethodSizeHandler.ForAdvicebindExit(MethodDescription.InDefinedShape adviceMethod, boolean skipThrowable)Binds the method size handler for the exit advice.intcompoundLocalVariableLength(int localVariableLength)Computes a compound local variable array length for the advice and the translated instrumented method.intcompoundStackSize(int stackSize)Computes a compound stack size for the advice and the translated instrumented method.voidrecordMaxima(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.voidrecordPadding(int padding)Records a minimum padding additionally to the computed stack size that is required for implementing this advice method.voidrequireLocalVariableLength(int localVariableLength)Requires a minimum length of the local variable array.voidrequireStackSize(int stackSize)Records a minimum stack size required by the represented advice method.static Advice.MethodSizeHandler.NoOpvalueOf(java.lang.String name)Returns the enum constant of this type with the specified name.static Advice.MethodSizeHandler.NoOp[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
INSTANCE
public static final Advice.MethodSizeHandler.NoOp INSTANCE
The singleton instance.
-
-
Method Detail
-
values
public static Advice.MethodSizeHandler.NoOp[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Advice.MethodSizeHandler.NoOp c : Advice.MethodSizeHandler.NoOp.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Advice.MethodSizeHandler.NoOp valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException- if this enum type has no constant with the specified namejava.lang.NullPointerException- if the argument is null
-
bindEnter
public Advice.MethodSizeHandler.ForAdvice bindEnter(MethodDescription.InDefinedShape adviceMethod)
Description copied from interface:Advice.MethodSizeHandler.ForInstrumentedMethodBinds a method size handler for the enter advice.- Specified by:
bindEnterin interfaceAdvice.MethodSizeHandler.ForInstrumentedMethod- Parameters:
adviceMethod- The method representing the enter advice.- Returns:
- A method size handler for the enter advice.
-
bindExit
public Advice.MethodSizeHandler.ForAdvice bindExit(MethodDescription.InDefinedShape adviceMethod, boolean skipThrowable)
Description copied from interface:Advice.MethodSizeHandler.ForInstrumentedMethodBinds the method size handler for the exit advice.- Specified by:
bindExitin interfaceAdvice.MethodSizeHandler.ForInstrumentedMethod- Parameters:
adviceMethod- The method representing the exit advice.skipThrowable-trueif the exit advice is not invoked on an exception.- Returns:
- A method size handler for the exit advice.
-
compoundStackSize
public int compoundStackSize(int stackSize)
Description copied from interface:Advice.MethodSizeHandler.ForInstrumentedMethodComputes a compound stack size for the advice and the translated instrumented method.- Specified by:
compoundStackSizein interfaceAdvice.MethodSizeHandler.ForInstrumentedMethod- Parameters:
stackSize- The required stack size of the instrumented method before translation.- Returns:
- The stack size required by the instrumented method and its advice methods.
-
compoundLocalVariableLength
public int compoundLocalVariableLength(int localVariableLength)
Description copied from interface:Advice.MethodSizeHandler.ForInstrumentedMethodComputes a compound local variable array length for the advice and the translated instrumented method.- Specified by:
compoundLocalVariableLengthin interfaceAdvice.MethodSizeHandler.ForInstrumentedMethod- Parameters:
localVariableLength- The required local variable array length of the instrumented method before translation.- Returns:
- The local variable length required by the instrumented method and its advice methods.
-
requireLocalVariableLength
public void requireLocalVariableLength(int localVariableLength)
Description copied from interface:Advice.MethodSizeHandlerRequires a minimum length of the local variable array.- Specified by:
requireLocalVariableLengthin interfaceAdvice.MethodSizeHandler- Parameters:
localVariableLength- The minimal required length of the local variable array.
-
requireStackSize
public void requireStackSize(int stackSize)
Description copied from interface:Advice.MethodSizeHandlerRecords a minimum stack size required by the represented advice method.- Specified by:
requireStackSizein interfaceAdvice.MethodSizeHandler- Parameters:
stackSize- The minimum size required by the represented advice method.
-
recordMaxima
public void recordMaxima(int stackSize, int localVariableLength)Description copied from interface:Advice.MethodSizeHandler.ForAdviceRecords the maximum values for stack size and local variable array which are required by the advice method for its individual execution without translation.- Specified by:
recordMaximain interfaceAdvice.MethodSizeHandler.ForAdvice- Parameters:
stackSize- The minimum required stack size.localVariableLength- The minimum required length of the local variable array.
-
recordPadding
public void recordPadding(int padding)
Description copied from interface:Advice.MethodSizeHandler.ForAdviceRecords a minimum padding additionally to the computed stack size that is required for implementing this advice method.- Specified by:
recordPaddingin interfaceAdvice.MethodSizeHandler.ForAdvice- Parameters:
padding- The minimum required padding.
-
-