Interface TestCaseActivity


public interface TestCaseActivity
Activity of a TestCase.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the code of the related error or escalation event.
    Returns the name of the related message or signal event.
    org.camunda.bpm.model.bpmn.instance.FlowNode
    Gets the underlying flow node.
    <T extends org.camunda.bpm.model.bpmn.instance.FlowNode>
    T
    getFlowNode(Class<T> flowNodeType)
    Gets the underlying flow node of the given type.
    Returns the ID of the underlying flow node.
    Returns the name of the underlying flow node.
    int
    Determines how deep the activity is nested within the BPMN process.
    Returns the next test activity, if this is not the last activity.
    Return the parent scope, if the underlying flow node is not a direct child of the BPMN process element.
    Returns the previous test activity, if this is not the first activity.
    Gets the topic name of an external task activity.
    Returns the type or TestCaseActivityType.OTHER, if there is no explicit type.
    Returns the name of the flow node element type.
    boolean
    Determines if the activity has a parent and the parent is a multi instance.
    boolean
    Determines if the activity has a successor.
    boolean
    Determines if the activity has a parent or if it is a direct child of the BPMN process element.
    boolean
    Determines if the activity has a predecessor.
    boolean
    Checks if the activity has a predecessor and the predecessor's type is the given type.
    boolean
    Returns true, if an asynchronous continuation after the activity is specified.
    boolean
    Returns true, if an asynchronous continuation before the activity is specified.
    boolean
    Checks if the activity is a boundary event, that is attached to the given activity.
    boolean
    Determines if the activity is a multi instance.
    boolean
    Determines if the activity is a parallel multi instance.
    boolean
    Determines if the activity is a sequential multi instance.
    boolean
    Returns true, if the activity is a start activity of the process.
    boolean
    Returns true, if the activity is an end activity of the process.
  • Method Details

    • getEventCode

      String getEventCode()
      Returns the code of the related error or escalation event.
      Returns:
      The event code or null, if the activity is not an error or escalation event or the code is not specified.
    • getEventName

      String getEventName()
      Returns the name of the related message or signal event.
      Returns:
      The event name or null, if the test activity is not related to a message or signal event.
    • getFlowNode

      org.camunda.bpm.model.bpmn.instance.FlowNode getFlowNode()
      Gets the underlying flow node.
      Returns:
      The activity's flow node.
    • getFlowNode

      <T extends org.camunda.bpm.model.bpmn.instance.FlowNode> T getFlowNode(Class<T> flowNodeType)
      Gets the underlying flow node of the given type.
      Type Parameters:
      T - A flow node type - e.g. IntermediateCatchEvent.
      Parameters:
      flowNodeType - A specific flow node type.
      Returns:
      The typed flow node.
    • getId

      String getId()
      Returns the ID of the underlying flow node.
      Returns:
      The activity ID.
    • getName

      String getName()
      Returns the name of the underlying flow node.
      Returns:
      The activity name.
    • getNestingLevel

      int getNestingLevel()
      Determines how deep the activity is nested within the BPMN process. Level 0, means that the activity is not nested in a scope (embedded sub process).
      Returns:
      The activity's nesting level.
    • getNext

      TestCaseActivity getNext()
      Returns the next test activity, if this is not the last activity.
      Returns:
      The activity's successors.
      Throws:
      IllegalStateException - If the activity has no successors.
      See Also:
    • getParent

      Return the parent scope, if the underlying flow node is not a direct child of the BPMN process element.
      Returns:
      The parent test case activity scope.
      Throws:
      IllegalStateException - If the activity has no parent.
      See Also:
    • getPrevious

      TestCaseActivity getPrevious()
      Returns the previous test activity, if this is not the first activity.
      Returns:
      The activity's predecessor.
      Throws:
      IllegalStateException - If the activity has no predecessor.
      See Also:
    • getTopicName

      String getTopicName()
      Gets the topic name of an external task activity.
      Returns:
      The topic name or null, if the activity is not an external task or the topic name is not specified.
    • getType

      Returns the type or TestCaseActivityType.OTHER, if there is no explicit type.
      Returns:
      The activity's type.
    • getTypeName

      String getTypeName()
      Returns the name of the flow node element type.
      Returns:
      The type name.
    • hasMultiInstanceParent

      boolean hasMultiInstanceParent()
      Determines if the activity has a parent and the parent is a multi instance.
      Returns:
      true, if the activity has a multi instance parent scope. Otherwise false.
      See Also:
    • hasNext

      boolean hasNext()
      Determines if the activity has a successor.
      Returns:
      true, if the activity has a successor. Otherwise false.
    • hasParent

      boolean hasParent()
      Determines if the activity has a parent or if it is a direct child of the BPMN process element.
      Returns:
      true, if the activity has a parent scope. Otherwise false.
    • hasPrevious

      boolean hasPrevious()
      Determines if the activity has a predecessor.
      Returns:
      true, if the activity has a predecessor. Otherwise false.
    • hasPrevious

      boolean hasPrevious(TestCaseActivityType type)
      Checks if the activity has a predecessor and the predecessor's type is the given type.
      Parameters:
      type - A specific test activity type.
      Returns:
      true, if a previous activity with the given type exists. Otherwise false.
    • isAsyncAfter

      boolean isAsyncAfter()
      Returns true, if an asynchronous continuation after the activity is specified.
      Returns:
      true, if the activity is asynchronous after. Otherwise false.
    • isAsyncBefore

      boolean isAsyncBefore()
      Returns true, if an asynchronous continuation before the activity is specified.
      Returns:
      true, if the activity is asynchronous before. Otherwise false.
    • isAttachedTo

      boolean isAttachedTo(TestCaseActivity activity)
      Checks if the activity is a boundary event, that is attached to the given activity.
      Parameters:
      activity - A specific activity.
      Returns:
      true, if the activity is attached to the given activity. Otherwise false.
    • isMultiInstance

      boolean isMultiInstance()
      Determines if the activity is a multi instance.
      Returns:
      true, if the activity is a multi instance. Otherwise false.
    • isMultiInstanceParallel

      boolean isMultiInstanceParallel()
      Determines if the activity is a parallel multi instance.
      Returns:
      true, if the activity is a parallel multi instance. Otherwise false.
      Throws:
      IllegalStateException - If the activity is not a multi instance.
    • isMultiInstanceSequential

      boolean isMultiInstanceSequential()
      Determines if the activity is a sequential multi instance.
      Returns:
      true, if the activity is a sequential multi instance. Otherwise false.
      Throws:
      IllegalStateException - If the activity is not a multi instance.
    • isProcessEnd

      boolean isProcessEnd()
      Returns true, if the activity is a start activity of the process.
      Returns:
      true, if the activity starts the process. Otherwise false.
    • isProcessStart

      boolean isProcessStart()
      Returns true, if the activity is an end activity of the process.
      Returns:
      true, if the activity ends the process. Otherwise false.