Some clarification about the UML Use Case diagram related to the type description field? [closed]

StackOverflow https://stackoverflow.com/questions/20958330

  •  25-09-2022
  •  | 
  •  

Frage

I have a doubt related to the UML Use Case diagram.

If I have an application in which I have the following situation:

the user can click on a button in a tab named My Drive that displays a view that show a list of virtual drive. In this view I also have a button named: Add a new virtual drive and if the user click on this button can add a new virtual drive

Now what is a virtual drive is not very important, whatever in this specific case a virtual drive is a virtual hard disk on my system.

So I have to formalize this situation with an UML Use Case diagram.

The actor is the user that interact with my application

So I think that I have a first use case that represent the situationmin which the user click on the My Drive button and see the list of the currently available virtual drive.

Using a table rappresentation of this use case something like this:

ID: UC01 USE CASE: Show detailed information about available virtual drive

Description: Functional operation that represents the user's request to display detailed information about the virtual drive to which it has access.

Type: PRIMARY, is a function of the system invoked directly by the user.

Actors: User (Main Actor), Application/Server (Secondary Actor).

Precondition: The user must be logged in to the system and the graphical interface that enables interaction with it must have been displayed.

Main Scenario (the normal course of the operation): The user click on the My Drive button into the main tabular menu and the detailed information about the available virtual drive are shown in a table.

Postcondition in case of Success: For each available virtual drive are displays the following information: SOME INFORMATION (not important here).

Postcondition in case of Failure: this situation is not expected, there should be no case of failure executing this operation.

Ok, I think that this template is correct and that the previous use case is ok. At this time I only have a doubt related the Type field of the previous template.

I have:

Type: PRIMARY, is a function of the system invoked directly by the user.

I was searching information about this description field and I have found nothing...so reasoning about it I have interpreted in this way: "if a user directly invoke a function on the system the type of the use case that represents this function have primary as value of the type field"

Is it ok or not?

Now I have to represent the use case related to the second function: the important observation is that I can perform the second operation (add a new Virtual Drive) only if first I runned the first operation (show the list of avaiable virtual drive).

So I have something like this:

ID: UC02 USE CASE: Add a new virtual drive to the list of avaiable virtual drive

Description: Functional operation that represents the user's request to add a new virtual drive to the list of avaiable virtual drive.

Type: ?????????????

Actors: User (Main Actor), Application/Server (Secondary Actor).

Precondition: The user must be logged into the system and the user must have shown the view related to the My Drive button

Postcondition in case of Success: Appear a new view that allows the user to add a new virtual drive to the list of the avaiable virtual drive.

Postcondition in case of Failure: this situation is not expected, there should be no case of failure executing this operation.

Now my doubt is related to the Type description field of this secondary use case.

This function is directly invoked by the user so, using the previous reasoning, this have to be PRIMARY (as the previous use case)

But elsewhere (in another example) I found that in this kind of use case the value of the Type description field have to be SECONDARY because it depends by the first use case (because the user first have to invoke the operation that show the list of all the avaiable virtual drive and then he can add a new virtual drive)

So, can you help me to do some clarification about this topic?

Tnx

Andrea

War es hilfreich?

Lösung

Just like you stumbled upon this issue, your readers may not be familiar with the term used ("type=primary"). Your objection, however, is to make a clear point.

So I'd go for the clearest possible solution:

You can use an << extend >> relationship from UC 2 to UC 1 to clarify the dependency on UC 1. Drop a written note in the UC precondition description which states the dependency in execution order in plain text.

Use Cases are not meant to specify dependencies in execution time or order. If you need that, use a UML activity diagram or UML sequence diagram, because they make this much clearer. You also greatly reduce the risk of your point being accidentally overlooked by thre recipients.

In your diagram, you may put a UML note with a hint that there is another diagram for these UC. Some tools allow for a hyperlink to the other diagram.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top