Annotation Type DynamicConstant
-
@Documented @Retention(RUNTIME) @Target(PARAMETER) public @interface DynamicConstant
Binds a dynamic constant to the annotated parameter. The constant is either bound by using constantdynamic or invokedynamic.
Important: Don't confuse this annotation with
Advice.DynamicConstant
orMemberSubstitution.DynamicConstant
. This annotation should be used withMethodDelegation
only.
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description java.lang.String
bootstrapName
Returns the name of the bootstrap method handle.java.lang.Class<?>[]
bootstrapParameterTypes
Returns the parameter types of the bootstrap method handle.java.lang.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.
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.Class<?>
bootstrapOwner
Returns the owner type of the bootstrap method handle, orvoid
, to represent the instrumented type.boolean
invokedynamic
Returnstrue
if invokedynamic should be used to bind the annotated parameter.java.lang.String
name
Returns the name of the dynamic constant that is supplied to the bootstrap method.
-
-
-
Element Detail
-
bootstrapType
JavaConstant.MethodHandle.HandleType bootstrapType
Returns the type of the bootstrap method handle to resolve.- Returns:
- The type of the bootstrap method handle to resolve.
-
-