You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Cameo Simulation Toolkit allows you to delay delivery of a pair of consecutive messages using a duration constraint. The default time unit of the duration constraint is the millisecond (ms), but you can also use other time units by specifying it after a duration value. For example, you can use 10s to denote 10 seconds. Cameo Simulation Toolkit uses the maximum value of a duration constraint to delay delivery of a message if you specify both the minimum and maximum values. 

Duration Constraints between Messages
A Sequence diagram showing how a duration constraint can be used to delay the delivery of a pair of consecutive messages.

The preceding figure shows that atm sent the first message to consortium to verify a card. The consortium replied the bank to verify the account by sending the second message after 100 milliseconds. The bank then sent the third message to the consortium after 2000 milliseconds (Cameo Simulation Toolkit uses the maximum value to delay delivery of the message). Finally, consortium sent a reply to atm by sending the fourth message 100 milliseconds after it received the third message. 


Duration constraints between a Call Message and Reply Message fail as breakpoint with a warning message on the Console pane.


Important

  • Duration constraints will be compared between Call Messages and Reply Messages and evaluated, which may fail with a warning message on the Console pane if the constraints are not satisfied.
  • The execution can stop at breakpoints by setting the Constraint Failure As Breakpoint option to true in the Specification window of «SimulationConfig».