Annotation Interface ReturnValue


@Retention(RUNTIME) @Target(PARAMETER) public @interface ReturnValue
Assigns the return value of the instrumented method to a parameter of a probe method. The probe method can be annotated with Interception, PayloadInterception or AdditionalInterception whose invokeOn argument is set to InvocationType.EXIT or InvocationType.RETURN. The type of the annotated parameter must be Object or the declared type of the parameter of the instrumented method. The declared type can only be used if it can be resolved by the system class loader.

If invokeOn is set to InvocationType.EXIT and the instrumented method throws an exception, the argument will be null.