Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

sequence diagram optional interactions

could please anyone share his/her wisdom regarding optional steps in sequence diagrams? :)

The seq. diagram describes a user registration process. In the attached image the marked message is optional, which means that he can go on with the registration process without filling in this info. But here it looks like he has to add it..

user registration process

The check of whether add. company name field is mandatory or not is being done when selecting Next. So my question is how should this be depicted in this sequence diagram?

Thank you all in advance.

like image 675
Joanna M. Avatar asked Jul 08 '26 21:07

Joanna M.


1 Answers

If that message is just optional, you can use an opt interaction operator in a combined fragment, like in the following example:

enter image description here

This means that "either the (sole) operand happens or nothing happens" (Source: UML Specification).

like image 148
Néstor Lucas Martínez Avatar answered Jul 14 '26 00:07

Néstor Lucas Martínez