@Documented @Retention(value=RUNTIME) @Target(value=PARAMETER) public static @interface MemberSubstitution.SelfCallHandle
Indicates that the annotated parameter should load a java.lang.invoke.MethodHandle
that represents an invocation of
the substituted expression or instrumented method. If the current method is virtual, it is bound to the current instance such
that the virtual hierarchy is avoided. This annotation cannot be used to acquire a handle on enclosing constructors.
Important: Don't confuse this annotation with Advice.SelfCallHandle
. This annotation should
be used only in combination with MemberSubstitution.Substitution.Chain.Step.ForDelegation
.
Modifier and Type | Optional Element and Description |
---|---|
boolean |
bound
Determines if the method is bound to the arguments and instance of the represented invocation.
|
MemberSubstitution.Source |
source
Determines the source that is considered for this annotation which can be either the substituted method,
constructor or field, or the instrumented method.
|
public abstract MemberSubstitution.Source source
Copyright © 2014–2025. All rights reserved.