All Known Implementing Classes:
AbortedFlowNodeState, AbortingActivityWithBoundaryState, AbortingBoundaryAndIntermediateCatchEventState, AbortingBoundaryEventsOnCompletingActivityState, AbortingCallActivityState, AbortingFlowNodeContainerState, AbortingFlowNodeState, AbortingReceiveTaskState, AbortingSubTaskState, CancelledFlowNodeState, CancellingActivityWithBoundaryState, CancellingBoundaryAndIntermediateCatchEventState, CancellingCallActivityState, CancellingFlowNodeContainerChildrenState, CancellingFlowNodeState, CancellingReceiveTaskState, CompletedActivityState, CompletingActivityState, CompletingCallActivityState, EndingCallActivityExceptionState, EndingFlowNodeContainerExceptionState, ExecutingAutomaticActivityState, ExecutingBoundaryEventState, ExecutingCallActivityState, ExecutingFlowNodeState, ExecutingLoopActivityState, ExecutingMultiInstanceActivityState, ExecutingThrowEventState, FailedActivityState, InitializingActivityState, InitializingActivityWithBoundaryEventsState, InitializingAndExecutingFlowNodeState, InitializingBoundaryEventState, InitializingLoopActivityState, InitializingMultiInstanceActivityState, InterruptingBoundaryAndIntermediateCatchEventState, OnEnterAndFinishConnectorState, OnEnterConnectorState, OnEnterOrOnFinishConnectorState, OnFinishConnectorState, ReadyActivityState, SkippedFlowNodeState, WaitingFlowNodeState

public interface FlowNodeState
Author:
Baptiste Mesta, Matthieu Chaffotte
  • Field Details

  • Method Details

    • getId

      int getId()
    • shouldExecuteState

      boolean shouldExecuteState(SProcessDefinition processDefinition, SFlowNodeInstance flowNodeInstance) throws SActivityExecutionException
      Parameters:
      processDefinition -
      flowNodeInstance -
      Returns:
      true the state must be executed, false if the execution must skip this state and go directly to the next one
      Throws:
      SActivityExecutionException
    • mustAddSystemComment

      boolean mustAddSystemComment(SFlowNodeInstance flowNodeInstance)
      Return true if flowNodeInstance instance of SHumanTaskInstance
      Parameters:
      flowNodeInstance -
      Returns:
      true or false
      Since:
      6.0
    • getSystemComment

      String getSystemComment(SFlowNodeInstance flowNodeInstance)
      Add a system comment "User XYZ has XYZ(state change) task XYZ(task name)"
      Parameters:
      flowNodeInstance -
      Returns:
      system comment "User XYZ has XYZ(state change) task XYZ(task name)"
      Since:
      6.0
    • execute

      Throws:
      SActivityStateExecutionException
    • notifyChildFlowNodeHasFinished

      default boolean notifyChildFlowNodeHasFinished(SProcessDefinition processDefinition, SFlowNodeInstance parentInstance, SFlowNodeInstance childInstance) throws SActivityStateExecutionException
      Called when a child of the flow node parentInstance finishes. Triggers what's next, if applicable. returns if all children activity is finished / triggered.
      Returns:
      true if the state is finished (the flow node will continue its flow), false if there are still some children to be triggered / to wait for.
      Throws:
      SActivityStateExecutionException
    • getName

      String getName()
    • isStable

      boolean isStable()
      Returns:
      true if the state is stable a final state is stable
    • isTerminal

      boolean isTerminal()
      Checks whether the state is a terminal one.
      Returns:
      true is the state is a terminal one; false otherwise
    • getStateCategory

      SStateCategory getStateCategory()
      Get the state's category
      Returns:
      the state's category