You can model Constraints of various types on a Sequence diagram, for both SysML and UML 2.5 support.
•IntervalConstraint – a general purpose interval constraint – the interval described by a formula such as an equation, inequation or more generally a relation.
•TimeConstraint – Time constraint is a constraint that refers to a time interval. The time interval is a time expression used to determine whether the constraint is satisfied.
•DurationConstraint – Duration constraint is an interval constraint that refers to a duration interval. The duration interval is a duration used to determine whether the constraint is satisfied.
•InteractionConstraint – represents groups of variables that are allowed to interact. Used as a Guard condition to specify whether an Interaction Operand runs in a Combined Fragment.
The Generic Line is used to model start and end regions of Constraints on a Sequence diagram for SysML and UML 2.5.
How to model a Constraint
To model a Constraint, complete the following steps – these steps use a DurationConstraint as an example:
1 Select the DurationConstraint symbol from the Draw toolbar, add it to the Sequence diagram, and then name it. The border of the Constraint symbol will disappear after drawing it.
2 In the DurationConstraint definition, click the + mark for the Specification property on page 2 of the DurationConstraint tab to add a new DurationInterval (alternatively click the Choices button to drag-and-drop an existing DurationConstraint into the definition).
3 In the DurationInterval definition, click the + mark on the max property on the DurationInterval tab, to add a new maximum Duration (alternatively click the Choices button to drag-and-drop an existing DurationInterval into the definition).
4 On page 2 of the DurationInterval tab, add a minimum Duration by either clicking the + mark to add a new Duration, or clicking Choices and dragging-and-dropping an existing Duration into the property.
How to link the DurationConstraint to the Lifeline
1 Use the GenericLine to connect the Lifeline to the Constraint at the points where the Duration starts and ends. For the line:
•Make sure its line style is set to Straight-Orthogonal (to access this setting, select the line, and then select Format > Symbol Format> Line Style).
•Add additional end points into the line if necessary (right-click the line, and then select Insert Line Segment).
•Make sure the arrowhead points at the Constraint (right-click the line, and select Associative to open the Associative Properties dialog, within which you can specify the direction of arrowheads).
2 Draw a similar Generic Line from the Lifeline to the bottom of the Constraint symbol.