Package net.bytebuddy.asm
Annotation Type Advice.Local
-
@Documented @Retention(RUNTIME) @Target(PARAMETER) public static @interface Advice.Local
Declares the annotated parameter as a local variable that is created by Byte Buddy for the instrumented method. The local variable can be both read and written by advice methods withAdvice.OnMethodEnter
andAdvice.OnMethodExit
annotation and are uniquely identified by their name. However, if a local variable is referenced from an exit advice method, it must also be declared by an enter advice method. It is possible to annotate multiple parameters of an advice method with local variables of the same name as long as all annotated parameters share the same parameter type. All local variables are initialized with their default value which is0
value for primitive types andnull
for reference types.
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description java.lang.String
value
The name of the local variable that the annotated parameter references.
-