Is there any "switch case" in UML use-case specification?

Susuri Yuyuki picture Susuri Yuyuki · Aug 30, 2015 · Viewed 14.2k times · Source

Is there any "switch case" in use-case specification?

In the requirements:

  • When user select "contract" in combobox, a "contract" tab appears, then user will interact with the "contract" tab.
  • When user select "Independently funded", a "Funding" tab appears, then user will interact with the "funding" tab.

How can I specify this use-case in my use-case specification?

Those two "case" will be in basic flow, won't they? Then how can I specify the "switch-case"?

Edit: (Because many mistakes what I'm doing, I will make it clear)

I'm not in progress of drawing use-case or drawing activity diagram, I'm in the between. I'm writing use-case specification (which is used to describe a use-case, and will be used later to draw activity diagram).

For more detail: https://www.google.com.vn/search?q=use-case+specification&biw=1280&bih=683&source=lnms&tbm=isch&sa=X&ved=0CAYQ_AUoAWoVChMIn6ujsMDRxwIVC5COCh3aNQGY#

Answer

qwerty_so picture qwerty_so · Aug 30, 2015

If you are describing the use case in the notes then write something like

Step m: User selects ?? from combobox. If selection is "contract" resume at Step n. If selection is "Funding" resume at Step o. ... ...

Step n: Resume at Step p.

Step o: Resume at Step p.

Step p: ...

where m, n, o and p are subsequent step numbers in your scenario.

If you are using Activities with Actions you can use a Decision node from where you have multiple outgoing transitions. Each transition then has a guard describing the switch (kind of a multi-if).

enter image description here