@Documented @Retention(value=RUNTIME) @Target(value=PARAMETER) public static @interface MemberSubstitution.DynamicConstant
Indicates that the annotated parameter should load a dynamic constant using the specificied bootstrap method. The constant can be bound using constantdynamic or invokedynamic.
Important: Don't confuse this annotation with Advice.DynamicConstant
or
DynamicConstant
. This annotation should be used only in
combination with MemberSubstitution.Substitution.Chain.Step.ForDelegation
.
Modifier and Type | Required Element and Description |
---|---|
String |
bootstrapName
Returns the name of the bootstrap method handle.
|
Class<?>[] |
bootstrapParameterTypes
Returns the parameter types of the bootstrap method handle.
|
Class<?> |
bootstrapReturnType
Returns the return type of the bootstrap method handle.
|
JavaConstant.MethodHandle.HandleType |
bootstrapType
Returns the type of the bootstrap method handle to resolve.
|
Modifier and Type | Optional Element and Description |
---|---|
Class<?> |
bootstrapOwner
Returns the owner type of the bootstrap method handle, or
void , to represent the instrumented type. |
boolean |
invokedynamic
Returns
true if invokedynamic should be used to bind the annotated parameter. |
String |
name
Returns the name of the dynamic constant that is supplied to the bootstrap method.
|
public abstract JavaConstant.MethodHandle.HandleType bootstrapType
public abstract String bootstrapName
public abstract Class<?> bootstrapReturnType
public abstract Class<?>[] bootstrapParameterTypes
public abstract String name
public abstract Class<?> bootstrapOwner
void
, to represent the instrumented type.void
, to represent the instrumented type.Copyright © 2014–2025. All rights reserved.