- 2070 Magh · 8 marks
Explain online order sequence diagram
Short answer
This sequence diagram shows interaction among objects in time order. Symbols: actor, lifelines with object boxes, activation bars, synchronous messages (solid arrowhead), asynchronous message (open arrowhead) to trigger bill, dashed return arrow, and a note for alternate scenario. Semantics: after submitOrder, OrderTaker processes card synchronously, then places order; OrderFulfillment triggers billing asynchronously; finally acknowledgment is returned.
The model depicts the online order processing system as illustrated in fig.1. Explain in detail of the diagram type with every symbols being used and semantics of this diagram. [Figure fig.1: sequence diagram with an actor and lifelines :OrderTaker, :CreditCardAgent, :OrderFulfillment, :BillingAgent. Messages: submitOrder (actor to :OrderTaker), processCard (:OrderTaker to :CreditCardAgent), placeOrder (:OrderTaker to :OrderFulfillment), triggerBill (:OrderFulfillment to :BillingAgent, asynchronous), acknowledgeOrder (return to the actor). A note reads "See Credit Failure for a variation of this scenario."]
The figure is a UML sequence diagram. It shows the interaction among objects for one scenario of order processing, with messages arranged in time order from top to bottom.
Actor :OrderTaker :CreditCard :Order :Billing
Agent Fulfillment Agent
|submitOrder| | | |
|---------->| | | |
| [ ]processCard| | |
| [ ]--------->[ ] | |
| [ ]<- - - - -[ ] | |
| [ ]placeOrder | |
| [ ]---------------------->[ ] |
| [ ] [ ]triggerBill
| [ ] [ ]- - - ->[ ]
|<- - - - -[ ] acknowledgeOrder | |
Note: "See Credit Failure for a variation of this scenario."
Symbols used
| Symbol | Meaning |
|---|---|
| Actor (stick figure or box) | External user/system starting the scenario |
Object box :OrderTaker | An anonymous instance of a class (name:Class, name omitted) at the top |
| Lifeline (dashed vertical line) | Existence of the object over time |
| Activation bar (thin rectangle) | Period when the object is active (focus of control) |
| Solid arrow with filled head | Synchronous message (caller waits) |
| Arrow with open/stick head | Asynchronous message (caller continues) |
| Dashed arrow | Return message |
| Note (folded corner) | Comment; here a pointer to another scenario |
Semantics (reading the diagram)
- The actor sends
submitOrderto:OrderTaker, which becomes active. :OrderTakersendsprocessCardto:CreditCardAgentto validate and charge the card, and waits for the result (synchronous).- If the card is accepted,
:OrderTakersendsplaceOrderto:OrderFulfillment. :OrderFulfillmentsendstriggerBillto:BillingAgentas an asynchronous message: it does not wait for billing to finish, and billing proceeds on its own.:OrderTakerreturnsacknowledgeOrderto the actor, confirming the order.- The note says the failure case (card rejected) is shown in a separate diagram "Credit Failure".
The diagram shows what collaborates and in which order, and identifies the operations (processCard, placeOrder, triggerBill) the classes must provide.
✓ Answer checked by Claude Opus 5.5 (high effort)
Related questions
- Map sequence diagram to pseudo code · Object Oriented Analysis and Design, chapter 4
- Food ordering system sequence diagram · Object Oriented Analysis and Design, chapter 2
- External actors and library system sequence diagram · Object Oriented Analysis and Design, chapter 2
- Money transfer sequence diagram questions · Object Oriented Analysis and Design, chapter 2
- Event management system summary and class diagram · Object Oriented Analysis and Design, chapter 2
- Block diagram reduction of Fig. 2(a): G1–G3, H1, H2 · Control Systems, chapter 3 · asked 2×
- Digital communication system; Shannon-Fano for six symbols · Communication Systems, chapter 6
- Five GPSS block diagram symbols · Simulation and Modeling, chapter 9 · asked 2×
- Plot sequence; properties of LTI system · Digital Signal Analysis and Processing, chapter 1
All Object Oriented Analysis and Design chapter 2 questions →