我正在调用一个函数,在该函数中检索带有需要在 tableviewCells 中显示的数据的 NSDictionary
。是否可以调用方法
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
用另一种方法?
最佳答案
不可能在另一个方法中调用一个特定的方法。但是,您可以在任何方法中调用 [self.tableView reloadData]
。这会调用所有 UITableView 委托(delegate)方法,其中包括 - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
关于ios - 是否可以在 for/in 循环中创建 UITableViewCells?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25312841/