Class Caller

java.lang.Object
com.cloudbees.groovy.cps.impl.Caller

public class Caller extends Object
As a crude way to distinguish asynchronous caller vs synchronous caller, remember the method call about to happen so that the callee can check if it is invoked by asynchronous caller or not.
Author:
Kohsuke Kawaguchi
  • Constructor Details

    • Caller

      public Caller()
  • Method Details

    • isAsynchronous

      public static boolean isAsynchronous(Object receiver, String method, Object... args)
      Checks if the method is called from asynchronous CPS transformed code.

      This method must be the first call in the function body.

    • isAsynchronous

      public static boolean isAsynchronous(Object receiver, String method)
    • isAsynchronous

      public static boolean isAsynchronous(Object receiver, String method, Object arg1)
    • isAsynchronous

      public static boolean isAsynchronous(Object receiver, String method, Object arg1, Object arg2)