Jump to Menu

How to Use Duration Constraint in Sequence Diagram?

In a UML sequence diagram, a duration message is used to indicate the passage of time of message. It's especially useful when you want to model a real-time system. With Visual Paradigm, you can add duration constraint to messages in one click. This tutorial will demonstrate this how to define duration constraint in sequence diagram.

Compatible edition(s): Enterprise, Professional, Standard, Modeler

  • August 16, 2010
  • Views: 82,572
  • PDF

  1. Download Online Book Store.vpp. You can also find this file at the bottom of this tutorial.
  2. Open the downloaded .vpp file in Visual Paradigm. To open a project, select Project > Open from the application toolbar.
  3. Let's take the following UML sequence diagram as an example:
    sample sequence diagram
  4. Assume you need to specify the time limit between Browse message and Book List message, you therefore, have to add duration constraint between them. Move the mouse over Browse message and press Duration Constraint button.
    click duration constraint
  5. Drag it from Browse message to Book List message and then release the mouse.
    drag line
  6. Enter the constraint detail inside the caption. For example, it should take more than 3 seconds but less than 5 minutes. You can enter > 3s & < 5mins.
    enter duration
  7. The duration constraint between Browse message and Book List message is shown below:
    created result
  8. On the other hand, you can add duration constraint not only between two message, but also on the message itself. Let's try to add duration constraint on Query message. Move the mouse over Query message and click Duration Constraint button.
    add duration constraint
  9. Assume it should take less than 10 seconds. Enter < 10s inside the caption.
    enter duration
  10. The duration constraint for Query message is shown below:
    duration result



Turn every software project into a successful one.

We use cookies to offer you a better experience. By visiting our website, you agree to the use of cookies as described in our Cookie Policy.

OK