Class diagram II Asper School of Business  University of Manitoba Systems Analysis & Design Instructor: Bob Travica Update...
Outline <ul><li>More on associations </li></ul><ul><li>Association class </li></ul><ul><li>Fully developed classes  </li><...
Associations <ul><li>One-to-many (most frequent; example: Customer—Order) </li></ul><ul><li>One-to-one (occasionally; exam...
Association class <ul><li>Two ways to think about it: </li></ul><ul><ul><li>1) A class that stores some extra attributes t...
RMO class diagram (simplified) 3510 Systems Analysis & Design * Bob Travica  of 9 <ul><li>Customary simplification: </li><...
Fully developed classes  (design level) 3510 Systems Analysis & Design * Bob Travica  of 9 Methods Attributes <ul><li>= pr...
How to get information  for class diagram <ul><li>The source of information can be: </li></ul><ul><ul><li>Description (nar...
Completing a class diagram <ul><li>Standard procedure: </li></ul><ul><li>1. List classes </li></ul><ul><li>2. List attribu...
Exercises <ul><li>Determine if Association Class is needed between the classes: </li></ul><ul><ul><li>1. Product – Supplie...
Upcoming SlideShare
Loading in …5
×

Class11

291 views
240 views

Published on

Published in: Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
291
On SlideShare
0
From Embeds
0
Number of Embeds
5
Actions
Shares
0
Downloads
1
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • PurchasingOrder(date, quantity) SaleTransaction(date) AdvertisementTVShow(date, price) AccountLedger(Date/TimeOfUpdate) LedgerPayable(Date/TimeOfUpdate) LoanedBook(CopyNumber, Overdue)
  • Class11

    1. 1. Class diagram II Asper School of Business University of Manitoba Systems Analysis & Design Instructor: Bob Travica Updated: October 2009
    2. 2. Outline <ul><li>More on associations </li></ul><ul><li>Association class </li></ul><ul><li>Fully developed classes </li></ul><ul><li>Completing procedure for creation of class diagrams </li></ul>3510 Systems Analysis & Design * Bob Travica of 9
    3. 3. Associations <ul><li>One-to-many (most frequent; example: Customer—Order) </li></ul><ul><li>One-to-one (occasionally; example: Customer—CustomerBillingAddress) </li></ul><ul><li>Many-to-many (moderately frequent; examples: </li></ul><ul><ul><li>Student—Course Section </li></ul></ul><ul><ul><li>Order—Item (Product) </li></ul></ul><ul><ul><li>Employee—Project </li></ul></ul>3510 Systems Analysis & Design * Bob Travica of 9
    4. 4. Association class <ul><li>Two ways to think about it: </li></ul><ul><ul><li>1) A class that stores some extra attributes that characterize associations between classes </li></ul></ul>3510 Systems Analysis & Design * Bob Travica of 9 2) A class that intermediates in many-to-many relationship (resolves variation that exists on both sides of association) term
    5. 5. RMO class diagram (simplified) 3510 Systems Analysis & Design * Bob Travica of 9 <ul><li>Customary simplification: </li></ul><ul><li>Show just maximum multi- </li></ul><ul><li>plicity </li></ul><ul><li>Just attributes of Association </li></ul><ul><li>Classes shown </li></ul>Figure 8-9 modified <ul><li>Association Entity consists of transaction data. </li></ul>Catalog ReturnItem Product Order ProductOrder Customer CatalogProduct productPrice InventoryItem Shipper * * 1 has * 1 * 1 * delivered by * 1 * 1 * has can be places delivered by appears on * * ReturnItemOrder dateReturned reason quantity Shipment ordered on * ProductShipment quantity quantity
    6. 6. Fully developed classes (design level) 3510 Systems Analysis & Design * Bob Travica of 9 Methods Attributes <ul><li>= private </li></ul><ul><li>+ = public </li></ul><ul><li>() = attribute affected or </li></ul><ul><li>input data </li></ul><ul><li>: string, number = data type </li></ul>Figure 8-7
    7. 7. How to get information for class diagram <ul><li>The source of information can be: </li></ul><ul><ul><li>Description (narrative) </li></ul></ul><ul><ul><li>Use case diagrams & descriptions </li></ul></ul><ul><ul><li>Use case table </li></ul></ul><ul><ul><li>Analyzing master data and transactional data </li></ul></ul>3510 Systems Analysis & Design * Bob Travica of 9
    8. 8. Completing a class diagram <ul><li>Standard procedure: </li></ul><ul><li>1. List classes </li></ul><ul><li>2. List attributes </li></ul><ul><li>3. Draw simplified class rectangles (name and attribute spaces only) </li></ul><ul><li>4. Insert attributes in class rectangles </li></ul><ul><li>5. Determine keys </li></ul><ul><li>6. Draw associations and name them </li></ul><ul><li>7. (New) Draw Association Class for each relationship that has attribute(s) on its own, or that you think is M:M. </li></ul>3510 Systems Analysis & Design * Bob Travica of 9
    9. 9. Exercises <ul><li>Determine if Association Class is needed between the classes: </li></ul><ul><ul><li>1. Product – Supplier </li></ul></ul><ul><ul><li>2. Product – SalesPerson </li></ul></ul><ul><ul><li>3. Advertisement – TVShow </li></ul></ul><ul><ul><li>4. Advertisement – MarketingAgency </li></ul></ul><ul><ul><li>5. BankAccount – TransactionLedger </li></ul></ul><ul><ul><li>6. GeneralLedger – AccountPayable </li></ul></ul><ul><ul><li>7. Book – LibraryLoan </li></ul></ul>3510 Systems Analysis & Design * Bob Travica of 9

    ×