Class Diagrams

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/11

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

12 Terms

1
New cards

+

public

2
New cards

-

private

3
New cards

#

protected

4
New cards

~

package

5
New cards
  • Association: General relationship

  • Aggregation (hollow diamond): "has-a", parts can exist independently

  • Composition (filled diamond): Strong ownership, parts die with whole

  • Generalization (triangle arrow): Inheritance

  • General relationship

6
New cards
term image
  • B inherits from A

  • A is a generalization

7
New cards
term image
  • B is a concrete implementation/realization of A

8
New cards
term image
  • A and B call eachother

9
New cards
term image
  • A can call B’s methods

  • But not visa versa

10
New cards
term image
  • Aggregation

  • A has one or more instances of B

  • B can survive if A is disposed

11
New cards
term image
  • Composition

  • A has one or more instances of B

  • B cannot survive if A is disposed

12
New cards

Building a Class Diagram

  • Identify classes

  • Identify attributes/properties

  • Identify operations

  • Indentify association types