Interface SimpleSessionContext

All Superinterfaces:
Serializable, UserAttributeContainer

public interface SimpleSessionContext extends Serializable, UserAttributeContainer
A session context that is simpler than the normal one. This is used for clients executing activities proprietarily not using ExecutableComponent. Therefore the session context is serialisable but does not provide any service logic but mere data.
Author:
Ulrich Kreher
  • Field Details

    • serialVersionUID

      static final long serialVersionUID
      Generated ID for serialisation.
      See Also:
  • Method Details

    • getSessionID

      String getSessionID()
      Returns the the session id that makes possible to identify the execution the session context belongs to.
      Returns:
      the session ID
      See Also:
    • isResumed

      boolean isResumed()
      Gets whether this session context is for resuming an activity (or a normal start).
      Returns:
      Whether this session context is for resuming an activity (or a normal start).
      See Also:
    • getSavepoint

      String getSavepoint()
      Gets the savepoint at which the execution is to be resumed if it is to be resumed at all. For normal starts and resuming without an explicitly set savepoint the returned savepoint is undefined (null).
      Returns:
      The identifier of the savepoint at which the execution is to be resumed if it is to be resumed at all. This will be null for normal starts and for resuming without an explicit savepoint.
      See Also:
    • getEBPInstanceReference

      EBPInstanceReference getEBPInstanceReference()
      Returns the reference to the corresponding process step which contains all information to identify the process step.
      Returns:
      The reference containing all information for identifying the corresponding process step of this execution.
      See Also:
    • getDataContext

      SerialisableDataContext getDataContext()
      Gets the data context, that is, an interface to get and set the values of all input and output parameters of an execution.
      Returns:
      The data context containing the values of the input parameters and providing the means to set the values of the output parameters.
      See Also:
    • getActivityInstance

      ActivityInstance getActivityInstance()
      Gets the activity instance of an execution, that is the complete process context, for instance the configuration of the activity in the process. This allows for generic executions.
      Returns:
      The activity instance of an execution, that is the complete process context.
    • isTestMode

      boolean isTestMode()
      Gets whether the execution is test mode. This method returns true, if the ExecutionManager told the RuntimeManager via the ExecutionContext at activity start to execute in the ExecutionMode.COMPONENT_TEST mode.

      isTestMode() and isViewOnly() are mutual exclusive just one of this flag is set if any.

      Returns:
      TRUE: Test mode is turned on FALSE: the execution is in a production environment
      See Also:
    • isViewOnly

      boolean isViewOnly()
      Gets whether the execution is in view only mode, that is, the values of the input and output parameters are just displayed but can not be changed. In case of the view only mode getDataContext() returns a read-only data context which allows to retrieve the values of output parameters.

      isTestMode() and isViewOnly() are mutual exclusive just one of this flag is set if any. But isViewOnly() can be mixed together with getCurrentEnquiry() and/or getRepliedEnquiry() which means that there is an enquiry or a reply for the execution but it has already been completely finished.

      Returns:
      Whether the component should run in view only mode.
      See Also:
    • getCurrentEnquiry

      Enquiry getCurrentEnquiry()
      Gets the current enquiry that was caused when executing. The current execution (using this session context) is done in enquiry mode, that means, the current agent should not finish this activity but merely reply to the enquiry and sent the answer back.

      If the execution does not have an enquiry, the returned Enquiry will be null. The reply will obviously always be null since it has not been replied to yet.

      Important: In case there is an enquiry for the current execution it should not be allowed to be closed but just to be suspended. Otherwise the agent sending the enquiry will only receive the reply but without the data the activity! Please note that the enquiry mode can be mixed together with isViewOnly(), this means, the execution is in view-only mode and has an open enquiry that needs to be replied.

      Returns:
      The enquiry set for assistance by the current agent or null if there is no enquiry for the current execution.
      See Also:
    • getRepliedEnquiry

      Enquiry getRepliedEnquiry()
      Gets the replied enquiry in case the execution has an enquiry (by the current user) and this has been replied now. The reply of the enquiry recipient is contained in the returned enquiry. This enquiry has been set in a previous execution and has been replied by the enquiry receiver.

      If the execution has not been made an enquiry for, the returned Enquiry will be null.

      Unlike getCurrentEnquiry() this enquiry is reply to a previous enquiry. If there is no current enquiry (getCurrentEnquiry() returns null), the execution can just be closed. Please note that the replied enquiry mode can be mixed together with isViewOnly(), this means, the execution is in view-only mode and has a reply for an enquiry.

      Returns:
      The enquiry set by the current agent needing assistance in the previous execution or null.
      See Also: