Package net.bytebuddy.asm
Class Advice.ArgumentHandler.ForAdvice.ForMethodExit
- java.lang.Object
-
- net.bytebuddy.asm.Advice.ArgumentHandler.ForAdvice.ForMethodExit
-
- All Implemented Interfaces:
Advice.ArgumentHandler,Advice.ArgumentHandler.ForAdvice
- Enclosing interface:
- Advice.ArgumentHandler.ForAdvice
public static class Advice.ArgumentHandler.ForAdvice.ForMethodExit extends java.lang.Object implements Advice.ArgumentHandler.ForAdvice
An argument handler for an exit advice method.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.asm.Advice.ArgumentHandler
Advice.ArgumentHandler.Factory, Advice.ArgumentHandler.ForAdvice, Advice.ArgumentHandler.ForInstrumentedMethod
-
Nested classes/interfaces inherited from interface net.bytebuddy.asm.Advice.ArgumentHandler.ForAdvice
Advice.ArgumentHandler.ForAdvice.ForMethodEnter, Advice.ArgumentHandler.ForAdvice.ForMethodExit
-
-
Field Summary
Fields Modifier and Type Field Description protected MethodDescriptionadviceMethodThe advice method.protected TypeDefinitionenterTypeThe enter type orvoidif no enter type is defined.protected MethodDescriptioninstrumentedMethodThe instrumented method.protected StackSizethrowableSizeThe stack size of a possibly stored throwable.-
Fields inherited from interface net.bytebuddy.asm.Advice.ArgumentHandler
THIS_REFERENCE
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedForMethodExit(MethodDescription instrumentedMethod, MethodDescription adviceMethod, TypeDefinition enterType, StackSize throwableSize)Creates a new argument handler for an exit advice.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intargument(int offset)Resolves an offset relative to an offset of the instrumented method.intenter()Resolves the offset of the enter value of the enter advice.intmapped(int offset)Resolves an offset of the advice method.intreturned()Resolves the offset of the returned value of the instrumented method.intthrown()Resolves the offset of the thrown exception of the instrumented method.
-
-
-
Field Detail
-
instrumentedMethod
protected final MethodDescription instrumentedMethod
The instrumented method.
-
adviceMethod
protected final MethodDescription adviceMethod
The advice method.
-
enterType
protected final TypeDefinition enterType
The enter type orvoidif no enter type is defined.
-
throwableSize
protected final StackSize throwableSize
The stack size of a possibly stored throwable.
-
-
Constructor Detail
-
ForMethodExit
protected ForMethodExit(MethodDescription instrumentedMethod, MethodDescription adviceMethod, TypeDefinition enterType, StackSize throwableSize)
Creates a new argument handler for an exit advice.- Parameters:
instrumentedMethod- The instrumented method.adviceMethod- The advice method.enterType- The enter type orvoidif no enter type is defined.throwableSize- The stack size of a possibly stored throwable.
-
-
Method Detail
-
argument
public int argument(int offset)
Description copied from interface:Advice.ArgumentHandlerResolves an offset relative to an offset of the instrumented method.- Specified by:
argumentin interfaceAdvice.ArgumentHandler- Parameters:
offset- The offset to resolve.- Returns:
- The resolved offset.
-
enter
public int enter()
Description copied from interface:Advice.ArgumentHandlerResolves the offset of the enter value of the enter advice.- Specified by:
enterin interfaceAdvice.ArgumentHandler- Returns:
- The offset of the enter value.
-
returned
public int returned()
Description copied from interface:Advice.ArgumentHandlerResolves the offset of the returned value of the instrumented method.- Specified by:
returnedin interfaceAdvice.ArgumentHandler- Returns:
- The offset of the returned value of the instrumented method.
-
thrown
public int thrown()
Description copied from interface:Advice.ArgumentHandlerResolves the offset of the thrown exception of the instrumented method.- Specified by:
thrownin interfaceAdvice.ArgumentHandler- Returns:
- The offset of the thrown exception of the instrumented method.
-
mapped
public int mapped(int offset)
Description copied from interface:Advice.ArgumentHandler.ForAdviceResolves an offset of the advice method.- Specified by:
mappedin interfaceAdvice.ArgumentHandler.ForAdvice- Parameters:
offset- The offset to resolve.- Returns:
- The resolved offset.
-
-