Where used: Event Diagram Model, State Machine Model


Control Condition


Read First: Operation, Event Type, Trigger Rule

An operation triggered by more than one event means that these triggers
are independent.  For example, in the diagram below, each trigger
calculates the input values of its target operation separately, and
operation D will execute three times:

Control conditions provide for making triggers to the same operation dependent on each other. For example, in the diagram below the triggers to D all share the same condition for proceeding:
Unless the user specifies otherwise, the condition requires that all triggering events occur before the triggers can succeed. This means that operation D executes only once. OOIE usually notates the default control condition by putting a small "&" the control condition node. Control conditions also provide for arbitrary calculations to be used as a test for proceeding. In particular, users can specify any boolean combination of the triggering events, which can sometimes lead to unpredictable execution results. For example, in the diagram above suppose that the control condition had this as its requirement: A is finished and B is finished or C is finished The execution pattern will depend on the order in which the operations complete. Here is one possible scenarios: A finishes first: Condition fails B finishes second: Condition succeeds C finishes third: Condition succeeds so, (D is executed three times. Here's another: C finishes first: Control Condition succeeds A finishes second: Control Condition succeeds B finishes third: Control Condition succeeds D is executed twice. Comparison to Operation Preconditions Control conditions and operation preconditions both determine whether an operation can proceed when it is triggered. Control conditions differ from preconditions because they can vary according to the trigger rule, whereas an operation's preconditions must be tested for all triggers into the operation. For example, the three triggers in the last section above could each have their own control condition, but they would all need to pass the precondition of operation D. Likewise, control conditions can vary from one use of the operation to another, whereas the precondition for an particular operation is the same for all uses of that operation. For example, operation D in the diagram above could be used in another diagram without a control condition, but both diagrams the triggers to D would need to pass its preconditions. Read First: Operation, Event Type, Trigger Rule


Hierarchy:

Attributes: None

Operations: