Creating A Use Case Diagram:: Using Rose
Creating A Use Case Diagram:: Using Rose
In the Window on the left side click on the "+" (plus) sign next to "Use Case View" 2. In the same window, double click on the icon next to "Main". This will open a blank Use Case
diagram called "Main" Adding an Actor 1. To create an Actor, click on the stick figure icon located on the toolbar in the middle of the screen. Then click on the diagram to place the Actor. 2. Open the Actor's specification by right clicking on the Actor (in the diagram) and select "Specification" from the pop-up menu. Fill in applicable fields. The specification can also be brought up by double clicking on the actor. Example: Add an Actor called "Elevator Rider" Adding a Use Case
1. In the toolbar, click on the oval shaped icon then click on the open diagram to place the use case. 2. Bring up the specification and fill in appropriate fields.
Example: Add a Use Case called "Ride Elevator" Adding an Association
1. Click on the association icon (a solid line with no arrowheads). Then, click on the actor first then
the use case. An association (line) will be drawn between the two. NOTE: Adding additional buttons to your toolbar: Using the Main Menu Bar (top of the screen) follow these steps:
a. Click on "Tools" b. Click on "Options" c. Click on the "Toolbars" tab Note that different diagrams have different toolbars
associated with them. You can add/remove buttons for each type of tools bar.
d. Click on the button with "..." in it next to the name of the diagram toolbar you want to
alter.
Creating a Class Diagram 1. In the left window, click on the "+" sign next to "Logical View" 2. Double click on the icon called "Main" underneath "Logical View". This opens the diagram
called "Main" Adding a class to the diagram 1. To add a class, click on the icon that looks like a rectangle divided into3 pieces. 2. Click somewhere in the diagram on the right to place the class. Type in a class name (Ex: ElevatorCar). Note you do not have to open a specification box to name the class (or any object) when you first place it in the diagram. As soon as you add the object, just type in a name. 3. Adding attributes to the Class a. Double click on the class to open the specification. b. Click on the "Attributes" tab. c. Right click in the column titled "Name" and select "Insert". d. Add an attribute (Ex: NumberButtons). Hit <return> e. Double click on the newly added attribute to open the specification for the attribute. f. Fill in additional information for the attribute here. 4. Adding operations a. Double click on the class to open the specification. b. Click on the "Operations" tab.
c. d. e. f.
Right click in the column "Signature" and select "Insert". Add a new operation (Ex: buttonPushed). Hit <return>. Double click on the operation (method) name to open the specification. Add additional detail here.
Example for making a Class Diagram: Go ahead and add a class called "ElevatorCar" with the above attribute and operation. Also, add a class called "Button", with an attribute "floor" and operation "pushed". Also, add an aggregation between the two classes. In the toolbar, click on the icon that has a diamond shaped head at one end of a solid line. Then click on the "Button" object in the diagram, then click on the "ElevatorCar" object in the diagram. The result should look like the diagram below:
5. In the left window, left-click once on the object to be added to the diagram and drag it onto the
newly created Collaboration diagram.
6. Use the other icons in the toolbar to create links between actors, classes, etc.
Example: 1. Click on the Actor "Elevator Rider" and drag and drop the object onto the diagram. 2. Drag and drop the "ElevatorCar" class onto the diagram. 3. Add the object "ElevatorCar" to the Collaboration diagram in the same manner. 4. Click on the Object Link icon (solid line). 5. Then click on the actor (in the diagram) and then then the "ElevatorCar" object (in the diagram). 6. Now, add a link message this way: a. Click on the "Link Message" icon (solid line with arrow pointing to the right above the solid line). b. Click on the just created object link. See diagram for what the collaboration diagram looks like:
1. Make sure the Collaboration diagram is the active diagram. (If you've been doing the examples
in order, it should already be active )