Let’s take a look at an example that starts to combine a lot of what you have learned to this point by creating an address book.2 Your address book will contain address cards. For the sake of simplicity, your address cards will contain only a person’s name and email address. Extending this concept to other information, such as address and phone number, is straightforward, but we leave that as an exercise for you at the end of this chapter.
2 OS X and iOS provide an entire Address Book framework that offers extremely powerful capabilities for working with address books.
The two classes we create, an
AddressCard class, and the relationship between the two are depicted in Figure 15.5.