O'Reilly logo

iOS® 8 for Programmers: An App-Driven Approach with Swift™, Third Edition by Abbey Deitel, Harvey M. Deitel, Paul J. Deitel

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

4.6.9 UITableViewDataSource Callback Methods

Several inherited UITableViewController methods are called by the UITableView to populate its cells and determine other information about the corresponding data. These methods (Figs. 4.334.36) are defined in the UITableViewDataSource protocol, which UITableViewController (and thus MasterViewController) implements. A UITableView gets its data from its data source—in this case, the Model. Xcode generated these methods as part of the Master-Detail Application template and we modified them to interact with our Model.

Determining the Number of Sections and the Number of Rows in Each Section

A UITableView may contain many sections—for example, an alphabetical list might have separate sections for each ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required