Search code examples
umluse-caseuse-case-diagram

Should I include System's tasks/responses in UML UseCase diagram?


There is an exercise that requires us to draw a usecase diagram for a bank, description says that a customer can make deposits and withdraw money. for that usecase scenario do i just draw "make deposit" and "withdraw money" ? or should I <<'include'>> "update balance" function for both of them as well ? useCase Diagram


Solution

  • There is a rule of gold that help me solve similar situations, hope it helps for you.

    Use case definition: Series of interaction between an actor and the system to obtain added value.

    So, as you can see there are interactions, basically a use case is a series of interactions.

    Which interactions are for update balance? None, is just a calculation the system (as opposed to the actor) does.

    Let's specify that use case under the assumption is a business use case and is a ATM.

    • 1) Actor1 press 'start button'
    • 2) The system show present card screen
    • 3) Actor1 present card
    • 4) System present menu with options...
    • 5) Actor1 select withdraw .... ...
    • 6) System present screen with updated balance
    • 7) Actor1 select ....

    So this is quite visual, is not a Use case in the first place, becouse there are no interactions involved. So there is no need to check if bring added value or not. Is just an important part of one of the many interactions involved.

    There are exceptions in which you may take that shortcut, such as if you want be more clear in the model or if you what to divide work based on Use cases. But IMHO that's not use case at all.

    You may have 'Show balance', but it would be only one interaction, with the exception if you have options like "show on screen" or "paper-print on a ATM"

    Hope it helps.