Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/tfs/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
MGTwitterEngine-在iPhone上使用GetImageAtull_Iphone_Cocoa Touch_Uitableview_Twitter_Mgtwitterengine - Fatal编程技术网

MGTwitterEngine-在iPhone上使用GetImageAtull

MGTwitterEngine-在iPhone上使用GetImageAtull,iphone,cocoa-touch,uitableview,twitter,mgtwitterengine,Iphone,Cocoa Touch,Uitableview,Twitter,Mgtwitterengine,基本上,我正在使用Matt Gemmell的MGTwitterEngine异步下载图像,并将它们添加到特定的UITableView单元格twitter配置文件图像中 我已经看过了一般异步下载代码,必须承认,我仍然是一个不懂的人,无法很好地理解它以适应我的目的。相反,我尝试使用Gemmell包含的getImageAtUrl方法来添加图像 我让它工作到-imageReceived:接收可见细胞的图像,但是,我被困在如何在该点将它们包含到适当的细胞中 - (void)imageReceived

基本上,我正在使用Matt Gemmell的MGTwitterEngine异步下载图像,并将它们添加到特定的UITableView单元格twitter配置文件图像中

我已经看过了一般异步下载代码,必须承认,我仍然是一个不懂的人,无法很好地理解它以适应我的目的。相反,我尝试使用Gemmell包含的getImageAtUrl方法来添加图像

我让它工作到-imageReceived:接收可见细胞的图像,但是,我被困在如何在该点将它们包含到适当的细胞中

    - (void)imageReceived:(UIImage *)image forRequest:(NSString *)identifier
{
    NSLog(@"Got an image:%@",image);
    // What goes here? Or elsewhere?
}
这个方法在我的主视图控制器中,我还有一个自定义的单元格控制器,我在其中使用它来绘制单元格内容


非常感谢使用此MGTwitterEngine方法或将这些图像动态添加到我的表格单元格中的任何帮助。

我从未使用过MGTwitterEngine,但通常我认为您需要:

找出图像所属的模型对象。我假设标识符字符串将在这方面帮助您

找出相应单元格的索引路径

调用[tableView cellForRowAtIndexPath:indexPath]获取表单元格

将图像放入单元格