Chapter 7

  1. See the discussion in section rec-scope.
  2. See the discussion in section inh-invariance.
  3. The diamond structure allows for separating the specification of an abstract interface of a compound object, its functional behavior, the way it is displayed and its actual realization. See section diamond.
  4. Overloading the de-reference operator allows one to bypass type checking on the level of the interface class. Dereferencing results in applying the function called to the de-referenced object. See slides sli-7-del-F and sli-7-del-A.
  5. Smart pointers may be introduced by overloading the de-reference operator. They are employed, for example, in the ODMG-93 standard to implement transparent references to both transitory and persistent objects. (The implementation is left as an exercise.)
  6. Dynamic role switching may be realized by introducing a so-called fat abstract interface class and employing a switch to invoke a function for the realization that matches the actual role. See section roles.
  7. A gadget is an item that may be found in a graphical user interface. The interaction between gadgets and windows takes place by callback functions. See section callback.
  8. An event is the result of a user action, such as clicking a mouse button. A gadget that has been declared sensitive to a particular user action must be notified if the corresponding event occurs. It may then respond with an appropriate action, if it considers the event of relevance. See section gadgets.
  9. See section comp-MVC.
  10. Event-driven control is not exclusive to window management systems. It may also be fruitfully applied to realize the actions occurring in response to operations of the user. User-defined events allow for the combination of system operations and the declaration of dependent events. As such, they provide an elegant means to maintain the integrity of a system. See section events.