ICS 121: UML Elevators Example

Overview

Elevators example

Elevators use case: Quickly using idle elevator

  1. User enters elevator on ground floor
  2. User presses floor 8 button
  3. Doors close
  4. Elevator moves up to desired floor
  5. Doors open
  6. User leaves

Elevators use case: Hold the door

  1. User1 enters elevator on ground floor
  2. User1 presses floor 8 button
  3. Doors start to close
  4. User1 sees User2 approaching
  5. User1 presses "open door" button
  6. Doors open fully
  7. User2 enters and sees floor 8 button already lit
  8. Doors close after 10 seconds
  9. Elevator moves up to desired floor
  10. Doors open
  11. User leaves

Elevators use case: Sharing a ride

  1. User1 enters elevator on ground floor
  2. User1 presses floor 8 button
  3. Doors close
  4. Elevator moves up to floor 3
  5. Doors open
  6. User2 enters and presses floor 6
  7. Doors close
  8. Elevator moves up to floor 6
  9. Doors open
  10. User2 leaves
  11. Doors close
  12. Elevator moves up to floor 8
  13. User1 leaves
  14. Doors close

What to notice about elevators use cases

Elevator class diagram

What to notice about elevators class diagram

Elevator state diagram

What to notice about elevators state diagram

example use case templatesample test plan templateProject plan template