您的位置:首页 > 移动开发 > Swift

Swift开发教程--实现UITableView报错does not conform to prot

2015-12-17 00:00 537 查看
通过实践,要是把下面三个协议方法都实现了就不会报错了。另外还需要注意!的问题。
func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int{
}
func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell{
}

func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath){

tableView.deselectRowAtIndexPath(indexPath, animated: true)
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  iOS