Class ExecutionFeature.ComponentSuspendable

java.lang.Object
jadex.execution.impl.ExecutionFeature.ComponentSuspendable
All Implemented Interfaces:
jadex.future.ISuspendable
Enclosing class:
ExecutionFeature

protected class ExecutionFeature.ComponentSuspendable extends Object implements jadex.future.ISuspendable
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected boolean
    Set by terminate() to indicate step abortion.
    protected boolean
    Check if currently blocked.
    protected jadex.future.Future<?>
    Provide access to future when suspended.
    protected ReentrantLock
    Use reentrant lock/condition instead of synchronized/wait/notify to avoid pinning when using virtual threads.
    protected Condition
     

    Fields inherited from interface jadex.future.ISuspendable

    SUSPENDABLE
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    Unblock and exit thread with ThreadDeath.
    jadex.future.IFuture<?>
     
     
    void
    resume(jadex.future.Future<?> future)
     
    void
    suspend(jadex.future.Future<?> future, long timeout, boolean realtime)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • blocked

      protected boolean blocked
      Check if currently blocked.
    • aborted

      protected boolean aborted
      Set by terminate() to indicate step abortion.
    • future

      protected jadex.future.Future<?> future
      Provide access to future when suspended.
    • lock

      protected ReentrantLock lock
      Use reentrant lock/condition instead of synchronized/wait/notify to avoid pinning when using virtual threads.
    • wait

      protected Condition wait
  • Constructor Details

    • ComponentSuspendable

      protected ComponentSuspendable()
  • Method Details

    • suspend

      public void suspend(jadex.future.Future<?> future, long timeout, boolean realtime)
      Specified by:
      suspend in interface jadex.future.ISuspendable
    • resume

      public void resume(jadex.future.Future<?> future)
      Specified by:
      resume in interface jadex.future.ISuspendable
    • abort

      protected void abort()
      Unblock and exit thread with ThreadDeath. Has no effect when not blocked.
    • getFuture

      public jadex.future.IFuture<?> getFuture()
      Specified by:
      getFuture in interface jadex.future.ISuspendable
    • getLock

      public ReentrantLock getLock()
      Specified by:
      getLock in interface jadex.future.ISuspendable