Classify the responsibilities of ticketing objects

A ticketing application assigns several kinds of responsibility to its objects. Match each category to the example that best illustrates it. Classify the behaviour explicitly described, rather than additional work the object might perform internally.

Match each term
A.

An Invoice calculates tax using its stored taxable total and tax rate.

B.

A Booking supplies its stored reference to the Seat assigned to it.

C.

A Seat reports the availability flag stored in that object.

D.

A Checkout asks a Basket to reserve its contents and a PaymentService to request payment.

Knowing a related object

Performing its own calculation

Coordinating collaborators

Knowing its own stored state

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

More Allocating Responsibilities to Classes Questions: