1

I have this diagram. The staff receives an email when his letter is approved. Do I need add an include relationship between two use cases? If I did that, it means the staff needs to approve letter to receive an email. It's different from the description.

enter image description here

Haru
  • 71
  • 5

1 Answers1

1

Definitely not. The simple reason is, that Receive Email is no use case. It is a pure function, likely used in some yet unknown use case. A use case brings added value to its actor. And receiving an email has no added value (like the dreaded Login).

It's hard to judge whether Approve Letter is a valid use case. It seems like a bit trivial. Probably if it's a certain letter in a certain process. As such, I would not let it go through as use case.

As always I recommend to read Bittner/Spence about use case modeling.

qwerty_so
  • 35,448
  • 8
  • 62
  • 86
  • I have actor A and B. A uses `Close Registration`. B uses `Collect Data`. The condition is that `Collect Data` can only happen if A closed registration. Do I need to add an `include` relationship? – Haru Apr 04 '22 at 13:31
  • @Haru technically it's a separate question. And the answer is again no. The fact of having a precondition isn't a reason to use include. Actually probably 98% of cases you'll ask whether to use include the answer will be no. The only reason when you need include is when the included use case can be run as a completely separate use case but the one that including it can't. Still, often it is better to depict it only in details (scenarios) of the UC rather than on the UC diagram, so often additionally required condition to show on the UC diagram is that inclusion *changes the list of actors*. – Ister Apr 04 '22 at 15:09
  • @Ister Right so. I'll look later since I'm pretty sure this question is a duplicate... – qwerty_so Apr 04 '22 at 15:11
  • Actuially there were a couple of answers. I took the above... – qwerty_so Apr 04 '22 at 16:05
  • @Haru from what you describe, the use case would probably be `Register` and `Close registration` as well as `collect data` would probably be actions in an activity diagram, in which you could show the sequencing (control flow), the exchange of information (object flow) and even parallel things (synchronisation) – Christophe Apr 05 '22 at 11:25