Search code examples
includeumluse-caseuse-case-diagram

Why there is no include link between create and delete use cases


I have seen on the internet many examples of use cases diagrams (in UML) as this one:

enter image description here

What I see is that the delete use case does not include the create use case. Even though I can't imagine deleting a user without creating it.

I wonder why it is still right to not use the include ? And I wonder when should I use it and when to not use it ?


Solution

  • If there is Delete-User - - <<include>> - -> Create-User that means during the execution of the UC Delete-User the UC Create-User is also executed, and of course that has no sense.

    The expected behavior can be :

    • Delete-User has the prerequisite Create-User was successfully executed for the same user and Delete-User was not already executed successfully for the same user (after the last Create-User then)
    • or Delete-User can be executed without prerequisite but if the user does not exist (Create-User was not executed successfully for the same user, or Delete-User was already executed for the same user after the last creation or the user) this is an error case