Interface SessionTaskDispatcher

All Superinterfaces:
TaskDispatcher, Terminatable
All Known Subinterfaces:
ModificationTracker
All Known Implementing Classes:
DefaultSessionTaskDispatcher

public interface SessionTaskDispatcher extends TaskDispatcher
A TaskDispatcher using a Session.
Author:
harald
  • Method Details

    • getSession

      Session getSession()
      Gets the session.
      Returns:
      the session
    • setSession

      void setSession(Session session)
      Sets the session.
      Parameters:
      session - the session
      Throws:
      TaskException - if dispatcher is already running or not invoked from the dispatcher thread
    • setSessionKeptAlive

      void setSessionKeptAlive(boolean sessionKeptAlive)
      Sets the keepalive flag.
      If set, setAlive() will be invoked periodically to keep the session alive.
      Parameters:
      sessionKeptAlive - true if ping enabled
    • isSessionKeptAlive

      boolean isSessionKeptAlive()
      Gets the keepalive flag.
      Returns:
      true if ping enabled
    • isSessionClosedOnTermination

      boolean isSessionClosedOnTermination()
      Returns whether the session should be closed on termination.
      Returns:
      true to close, false to leave it open
    • setSessionClosedOnTermination

      void setSessionClosedOnTermination(boolean sessionClosedOnTermination)
      Sets whether the session should be closed on termination.
      Parameters:
      sessionClosedOnTermination - true to close, false to leave it open