Skip to main content

Food ordering system sequence diagram

Short answer

Customer requests a seat; system coordinates with SeatingManager for table assignment. The customer then views menu, adds items in a loop, confirms order, requests bill, makes payment, and releases the table. System responds with table number, menu, order number, bill, and receipt.

Construct a system sequence diagram for customer from a "Food ordering system" of a very busy restaurant where seating and ordering is regulated by seating manager.

A system sequence diagram (SSD) treats the whole system as one black box (:System) and shows the events that the actor (Customer) generates and the system's responses, in time order.

Assumptions: the restaurant is busy, so the seating manager gives the customer a table (seat) first, then the customer orders, eats, and pays. The customer interacts with the system through a tablet/terminal. Actors: Customer, SeatingManager (supporting actor).

 Customer      :FoodOrdering System    SeatingManager
    | requestSeat(partySize) |               |
    |----------------------->|               |
    |                        |  findTable()  |
    |                        |-------------->|
    |                        |<- - - - - - - |
    |<- - - tableNo or wait--|               |
    | viewMenu()             |               |
    |----------------------->|               |
    |<- - - - menu - - - - - |               |
    | loop  [more items]                     |
    | addItem(itemId, qty)   |               |
    |----------------------->|               |
    |<- - - - - item added - |               |
    | end loop                               |
    | confirmOrder()         |               |
    |----------------------->|               |
    |<- - - orderNo, total - |  (sent to kitchen)
    | requestBill()          |               |
    |----------------------->|               |
    |<- - - - - bill - - - - |               |
    | makePayment(amount)    |               |
    |----------------------->|               |
    |<- - - - receipt - - - -|               |
    |                        | releaseTable()|
    |                        |-------------->|

Explanation of the events

  1. requestSeat - system asks the seating manager for a free table; if none is free, the customer is put in a waiting queue.
  2. viewMenu - system returns the menu.
  3. addItem repeated in a loop for each dish.
  4. confirmOrder - order number and total returned; kitchen is notified.
  5. requestBill, makePayment - bill and receipt are produced.
  6. Table is released so the next party can be seated.

Dashed lines are returns. The loop fragment shows repetition of addItem.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Object Oriented Analysis and Design chapter 2 questions →