When an object receives a message, the implementation triggered depends on the mode or state of the object. As opposed to roles and views, clients need not be aware of the current mode at the call site. Although we do not show the details, each plane should have a schedule of flying times interleaved with maintenance periods. Attributes pertaining to flying and maintenance should be visible to different parts of the system. For example, a reservation may be open, confirmed, or cancelled, and a plane may be available, in use, grounded, or lost.
Modes correspond to union types in traditional languages.
Object-oriented programming with modes . In European Conference on Object-Oriented Programming, 1992. No context found. Taivalsaari, A., Object-oriented programming with modes . No context found.