Making Connections
When the Quiz application loads its interface from MainWindow.xib, the objects that make up the interface are floating around in memory. The QuizAppDelegate (a controller object) needs to know where the labels (view objects) are in memory so that it can tell them what to display. The buttons (view objects that the user interacts with) need to know where the QuizAppDelegate is so that they can report when they are tapped. Your objects need connections. A connection lets an object know where another object is in memory.
Figure 1.14 shows the connections for Quiz. Some have already been made by the template (between the window outlet of QuizAppDelegate and the UIWindow instance, for example), and some were made implicitly (dragging ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access