IOS学习笔记---Two ways of getting data

来源:互联网 发布:python遍历字符串索引 编辑:程序博客网 时间:2024/06/11 17:55

Table views havetwo ways of getting data—statically or dynamically. When a table view’s controller implements the required UITableViewDataSource methods, the table view asks its view controller for data to display, regardless of whether static data has been configured in Interface Builder. If you look at XYZToDoListViewController.m, you’ll notice that it implements three methods—numberOfSectionsInTableView:tableView:numberOfRowsInSection:, and tableView:cellForRowAtIndexPath:. You can get your static data to display again by commenting out the implementations of these methods. Go ahead and try that out if you like.


原创粉丝点击