UML - Sequential Diagram, How to Show an Alternative Course

I have a function called logon (uname, pass) that returns a success or error message. Should I show this as an ALT fragment?

I basically after converting this use case into a sequence diagram:

> main flow: > 1. User provide username password. > 2. Display successful message after logon. > > alternate flow: > 1. User provide invalid username and passsword. > 2. Display invalid username or passwrod message. 

thanks

0
source share
2 answers

See this example .

Having said that, I with @Tanparmaiel prefer an activity diagram for alternatives: much more visually intuitive.

NTN.

+1
source

You should use the Activity Diagram , which displays the workflow of actions / actions of your application. The sequence diagram shows how processes interact with each other and in what order.

0
source

Source: https://habr.com/ru/post/918199/


All Articles