Download presentation
Presentation is loading. Please wait.
Published byJessie Baldwin Modified over 9 years ago
1
UML Overview
2
UML Diagrams to be Covered Class Diagrams Use Case Diagrams Collaboration Diagrams Sequence Diagrams Package Diagrams Component Diagrams Deployment Diagrams Activity Diagrams State Diagrams Class Diagrams Use Case Diagrams Collaboration Diagrams Sequence Diagrams Package Diagrams Component Diagrams Deployment Diagrams Activity Diagrams State Diagrams
3
Class Diagrams Are the most fundamental UML Diagram. Describe the classes in the system, and the static relationships between classes. Class diagrams are used during Analysis, Design and Development. Are the most fundamental UML Diagram. Describe the classes in the system, and the static relationships between classes. Class diagrams are used during Analysis, Design and Development.
4
UML Class Diagram DVD MovieVHS MovieVideo Game Rental Item {abstract} Rental Invoice 1..* 1 Customer Checkout Screen 1 0..1 1
5
DVD MovieVHS MovieVideo Game Rental Item {abstract} Rental Invoice 1..* 1 Customer Checkout Screen 0..1 1 Simple Association Class Abstract Class Simple Aggregation Generalization Composition (Dependency) Multiplicity UML Class Diagram
6
Parts of a Class Classes can have four parts –Name –Attributes –Operations –Responsibilities Classes can show visibility and types. All parts but the Name are optional. Classes can have four parts –Name –Attributes –Operations –Responsibilities Classes can show visibility and types. All parts but the Name are optional. MyClassName +SomePublicAttribute : SomeType -SomePrivateAttribute : SomeType #SomeProtectedAttribute : SomeType +ClassMethodOne() +ClassMethodTwo() Responsibilities -- can optionally be described here.
7
Object Diagrams An Object is an instance of a class. Object names are underlined. Object diagrams are similar to class diagrams. Many of the same notations are used. Object diagrams capture instances of classes, and allow the dynamic relationships to be shown. An Object is an instance of a class. Object names are underlined. Object diagrams are similar to class diagrams. Many of the same notations are used. Object diagrams capture instances of classes, and allow the dynamic relationships to be shown. ThisOne : MyClassName +SomePublicAttribute : SomeType -SomePrivateAttribute : SomeType #SomeProtectedAttribute : SomeType +ClassMethodOne() +ClassMethodTwo()
8
Class and Object Diagrams 0..1 0..n Customer Rental Item Rents +name:string +id:integer +released:date +id:integer Joe: CustomerCasablanca: Movie +name:Joe Smith +id:1667 +released:1942 +id:22340 Class Diagram Object Diagram Class Name Object Name Attributes Association Name
9
Stereotypes, Tagged Values and Constraints extend the UML –Stereotypes are shown using > –Tagged Values and Constraints are shown using { } RentalContract > {version=1.1} ListOfRentedItems Customer { ordered by title } Constraint Tagged Value Stereotype Stereotypes, Tagged Values and Constraints
10
Use Cases Describe interactions between users and computer systems (both called actors). Capture user-visible functions. Achieve discrete measurable goals. Are typically used during Analysis and Design. Describe interactions between users and computer systems (both called actors). Capture user-visible functions. Achieve discrete measurable goals. Are typically used during Analysis and Design.
11
Use Case Diagram Telephone Customer In-Store Customer Clerk Identify Movie Open Account Return Movie Customer Review Account Status Actor Use Case
12
Collaboration Diagrams Collaboration diagrams describe object interactions organized around the objects and their links to each other Focus on exchange of messages between objects through their associations. Appears during Analysis phase Enhanced during Design phase Collaboration diagrams describe object interactions organized around the objects and their links to each other Focus on exchange of messages between objects through their associations. Appears during Analysis phase Enhanced during Design phase
13
:Check-out Manager :Customer :Inventory 1: enter_customer() 3: enter_movies() 5: add(customer, movies) 7: print invoice() 2: IsValidCust(CustId) 4:GetMovieByBarcode() Collaboration Diagram - Rent Movie :Clerk Object Message :Rented Items 8: generateRentalTotal()
14
Sequence Diagrams Describe interactions between objects arranged in time sequence Focus on objects and classes involved in the scenario and the sequence of messages exchanged Associated with use cases Used heavily during Analysis phase and are enhanced and refined during Design phase Describe interactions between objects arranged in time sequence Focus on objects and classes involved in the scenario and the sequence of messages exchanged Associated with use cases Used heavily during Analysis phase and are enhanced and refined during Design phase
15
Sequence Diagram - Rent Movie 1: find customer() 2: search (string) 4: search (string) 6: add(Cust, item) 3: enter movie() 5: rent (movie) 7: printInvoice() 8: generateRentalTotal() Object Lifeline Activation Message :CheckoutMgr:InventoryCust:Customer:RentedItems : Employee
16
Package Diagram Class Package
17
Component Diagram Component Interface Dependency Note
18
Node Communication Association Deployment Diagram
19
Identify Caller Create Account Obtain Name & Address Open Account? Current Customer? [no] [yes] Action State Start State Decision End State Activity Diagram
20
Identify Movie Place Order Place Order Fill Order Pay Deliver Movie Pickup Movie CustomerManagerWalking Clerk Fork Point Join Point Collect Money Swimlanes and Fork/Join Points
21
State Diagram State Transition Activity Guard Action Event
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.