Quiz Entry - updated: 2026.07.14
What is the difference between <<include>> and <<extend>> relationships in Use Case Diagrams?
<<include>> = the base case ALWAYS runs the included one (mandatory, factor-out-common). <<extend>> = the extending case runs only SOMETIMES, under a condition (optional add-on).
The two are easy to mix up because their arrows point in opposite directions:
| Aspect | <<include>> |
<<extend>> |
|---|---|---|
| Arrow direction | Base → included | Extension → base |
| Execution | Always | Only when a condition holds |
| Purpose | Factor out shared behaviour | Bolt on optional behaviour |
| Reads as | "Base includes X" | "X extends Base" |
Airline example (mind the arrow direction):
- Check-In Passenger
<<include>>Assign Seat — every check-in must assign a seat (arrow points from Check-In to Assign Seat) - Check-In Passenger
<<include>>Weigh Luggage — every check-in must weigh luggage - Assign Window Seat
<<extend>>Assign Seat — Assign Window Seat is the extension; its arrow points TO the base Assign Seat, and it only fires if a window was requested - Assign Aisle Seat
<<extend>>Assign Seat — likewise, only if an aisle was requested
Tip: The extension always points TO the base it adds to. Saying "Assign Seat extends Assign Window Seat" is backwards — the specialised, optional behaviour (window seat) is the extending case.