UML Designer User's Guide

Generating stub method implementations

At this point, although we have specified that the class design conforms to a protocol, the actual Catalog class does not yet have real methods corresponding to the ones in the class design. To have UML Designer generate stub implementations, follow these steps:

  1. Select Transforms>Generate Real Class from the pop-up menu of the Catalog class figure.
  2. In the window that appears, select Catalog as the name of the class to generate.
  3. Select Replace Existing to indicate that we want to regenerate a class that already exists in the image.
  4. Select OK.

After the operation completes, the notation of the method signatures in the class figure should change to indicate that the methods are now implemented.
Class figure illustration (5)

To see the actual implementations, double-click on the Catalog class figure (or select Open With>Class Browser from its pop-up menu) to open a class browser on the Catalog class. You should see a new method category, generated, which contains stub implementations of the methods specified in the <Catalog> protocol.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]