Class UpdateDispatchFutureWait

java.lang.Object
com.espertech.esper.runtime.internal.kernel.updatedispatch.UpdateDispatchFutureWait
All Implemented Interfaces:
com.espertech.esper.common.internal.statement.dispatch.Dispatchable

public class UpdateDispatchFutureWait extends Object implements com.espertech.esper.common.internal.statement.dispatch.Dispatchable
UpdateDispatchFutureWait can be added to a dispatch queue that is thread-local. It represents is a stand-in for a future dispatching of a statement result to statement listeners.

UpdateDispatchFutureWait is aware of future and past dispatches: (newest) DF3 <--> DF2 <--> DF1 (oldest)

  • Constructor Details

    • UpdateDispatchFutureWait

      public UpdateDispatchFutureWait(UpdateDispatchViewBlockingWait view, UpdateDispatchFutureWait earlier, long msecTimeout)
      Ctor.
      Parameters:
      view - is the blocking dispatch view through which to execute a dispatch
      earlier - is the older future
      msecTimeout - is the timeout period to wait for listeners to complete a prior dispatch
    • UpdateDispatchFutureWait

      public UpdateDispatchFutureWait()
      Ctor - use for the first future to indicate completion.
  • Method Details

    • isCompleted

      public boolean isCompleted()
      Returns true if the dispatch completed for this future.
      Returns:
      true for completed, false if not
    • setLater

      public void setLater(UpdateDispatchFutureWait later)
      Hand a later future to the dispatch to use for indicating completion via notify.
      Parameters:
      later - is the later dispatch
    • execute

      public void execute()
      Specified by:
      execute in interface com.espertech.esper.common.internal.statement.dispatch.Dispatchable
    • getView

      public com.espertech.esper.common.internal.statement.dispatch.UpdateDispatchView getView()
      Specified by:
      getView in interface com.espertech.esper.common.internal.statement.dispatch.Dispatchable
    • cancelled

      public void cancelled()
      Specified by:
      cancelled in interface com.espertech.esper.common.internal.statement.dispatch.Dispatchable