Package net.bytebuddy.asm
Enum Advice.StackMapFrameHandler.NoOp
- java.lang.Object
-
- java.lang.Enum<Advice.StackMapFrameHandler.NoOp>
-
- net.bytebuddy.asm.Advice.StackMapFrameHandler.NoOp
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<Advice.StackMapFrameHandler.NoOp>,Advice.StackMapFrameHandler,Advice.StackMapFrameHandler.ForAdvice,Advice.StackMapFrameHandler.ForInstrumentedMethod,Advice.StackMapFrameHandler.ForPostProcessor
- Enclosing interface:
- Advice.StackMapFrameHandler
public static enum Advice.StackMapFrameHandler.NoOp extends java.lang.Enum<Advice.StackMapFrameHandler.NoOp> implements Advice.StackMapFrameHandler.ForInstrumentedMethod, Advice.StackMapFrameHandler.ForAdvice
A non-operational stack map frame handler.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.asm.Advice.StackMapFrameHandler
Advice.StackMapFrameHandler.Default, Advice.StackMapFrameHandler.ForAdvice, Advice.StackMapFrameHandler.ForInstrumentedMethod, Advice.StackMapFrameHandler.ForPostProcessor, Advice.StackMapFrameHandler.NoOp
-
-
Enum Constant Summary
Enum Constants Enum Constant Description INSTANCEThe singleton instance.
-
Constructor Summary
Constructors Modifier Constructor Description privateNoOp()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Advice.StackMapFrameHandler.ForAdvicebindEnter(MethodDescription.TypeToken typeToken)Binds this metadata handler for the enter advice.Advice.StackMapFrameHandler.ForAdvicebindExit(MethodDescription.TypeToken typeToken)Binds this metadata handler for the exit advice.intgetReaderHint()Returns a hint to supply to aClassReaderwhen parsing an advice method.voidinjectCompletionFrame(org.objectweb.asm.MethodVisitor methodVisitor)Injects a frame indicating the completion of the currently handled method, i.e.voidinjectExceptionFrame(org.objectweb.asm.MethodVisitor methodVisitor)Injects a frame indicating the beginning of an exception handler for the currently handled method.voidinjectInitializationFrame(org.objectweb.asm.MethodVisitor methodVisitor)Injects a frame after initialization if any initialization is performed.voidinjectIntermediateFrame(org.objectweb.asm.MethodVisitor methodVisitor, java.util.List<? extends TypeDescription> stack)Injects a frame that represents the current state.voidinjectPostCompletionFrame(org.objectweb.asm.MethodVisitor methodVisitor)Injects a frame indicating the completion of the currently handled method, i.e.voidinjectReturnFrame(org.objectweb.asm.MethodVisitor methodVisitor)Injects a frame indicating the beginning of a return value handler for the currently handled method.voidinjectStartFrame(org.objectweb.asm.MethodVisitor methodVisitor)Injects a frame before executing the instrumented method.voidtranslateFrame(org.objectweb.asm.MethodVisitor methodVisitor, int type, int localVariableLength, java.lang.Object[] localVariable, int stackSize, java.lang.Object[] stack)Translates a frame.static Advice.StackMapFrameHandler.NoOpvalueOf(java.lang.String name)Returns the enum constant of this type with the specified name.static Advice.StackMapFrameHandler.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.StackMapFrameHandler.NoOp INSTANCE
The singleton instance.
-
-
Method Detail
-
values
public static Advice.StackMapFrameHandler.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.StackMapFrameHandler.NoOp c : Advice.StackMapFrameHandler.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.StackMapFrameHandler.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.StackMapFrameHandler.ForAdvice bindEnter(MethodDescription.TypeToken typeToken)
Binds this metadata handler for the enter advice.- Specified by:
bindEnterin interfaceAdvice.StackMapFrameHandler.ForInstrumentedMethod- Parameters:
typeToken- The type token representing the advice method.- Returns:
- An appropriate metadata handler for the enter method.
-
bindExit
public Advice.StackMapFrameHandler.ForAdvice bindExit(MethodDescription.TypeToken typeToken)
Binds this metadata handler for the exit advice.- Specified by:
bindExitin interfaceAdvice.StackMapFrameHandler.ForInstrumentedMethod- Parameters:
typeToken- The type token representing the advice method.- Returns:
- An appropriate metadata handler for the enter method.
-
getReaderHint
public int getReaderHint()
Returns a hint to supply to aClassReaderwhen parsing an advice method.- Specified by:
getReaderHintin interfaceAdvice.StackMapFrameHandler.ForInstrumentedMethod- Returns:
- The reader hint to supply to an ASM class reader.
-
translateFrame
public void translateFrame(org.objectweb.asm.MethodVisitor methodVisitor, int type, int localVariableLength, @MaybeNull java.lang.Object[] localVariable, int stackSize, @MaybeNull java.lang.Object[] stack)Translates a frame.- Specified by:
translateFramein interfaceAdvice.StackMapFrameHandler- Parameters:
methodVisitor- The method visitor to write the frame to.type- The frame's type.localVariableLength- The local variable length.localVariable- An array containing the types of the current local variables.stackSize- The size of the operand stack.stack- An array containing the types of the current operand stack.
-
injectReturnFrame
public void injectReturnFrame(org.objectweb.asm.MethodVisitor methodVisitor)
Injects a frame indicating the beginning of a return value handler for the currently handled method.- Specified by:
injectReturnFramein interfaceAdvice.StackMapFrameHandler- Parameters:
methodVisitor- The method visitor onto which to apply the stack map frame.
-
injectExceptionFrame
public void injectExceptionFrame(org.objectweb.asm.MethodVisitor methodVisitor)
Injects a frame indicating the beginning of an exception handler for the currently handled method.- Specified by:
injectExceptionFramein interfaceAdvice.StackMapFrameHandler- Parameters:
methodVisitor- The method visitor onto which to apply the stack map frame.
-
injectCompletionFrame
public void injectCompletionFrame(org.objectweb.asm.MethodVisitor methodVisitor)
Injects a frame indicating the completion of the currently handled method, i.e. all yielded types were added.- Specified by:
injectCompletionFramein interfaceAdvice.StackMapFrameHandler- Parameters:
methodVisitor- The method visitor onto which to apply the stack map frame.
-
injectInitializationFrame
public void injectInitializationFrame(org.objectweb.asm.MethodVisitor methodVisitor)
Injects a frame after initialization if any initialization is performed.- Specified by:
injectInitializationFramein interfaceAdvice.StackMapFrameHandler.ForInstrumentedMethod- Parameters:
methodVisitor- The method visitor to write any frames to.
-
injectStartFrame
public void injectStartFrame(org.objectweb.asm.MethodVisitor methodVisitor)
Injects a frame before executing the instrumented method.- Specified by:
injectStartFramein interfaceAdvice.StackMapFrameHandler.ForInstrumentedMethod- Parameters:
methodVisitor- The method visitor to write any frames to.
-
injectPostCompletionFrame
public void injectPostCompletionFrame(org.objectweb.asm.MethodVisitor methodVisitor)
Injects a frame indicating the completion of the currently handled method, i.e. all yielded types were added.- Specified by:
injectPostCompletionFramein interfaceAdvice.StackMapFrameHandler.ForInstrumentedMethod- Parameters:
methodVisitor- The method visitor onto which to apply the stack map frame.
-
injectIntermediateFrame
public void injectIntermediateFrame(org.objectweb.asm.MethodVisitor methodVisitor, java.util.List<? extends TypeDescription> stack)Injects a frame that represents the current state.- Specified by:
injectIntermediateFramein interfaceAdvice.StackMapFrameHandler.ForPostProcessor- Parameters:
methodVisitor- The method visitor onto which to apply the stack map frame.stack- A list of types that are currently on the stack.
-
-