- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
我已经将 RestKit 安装到 Xcode 中并且构建良好。但是,我似乎在很多课上都不见了。我正在尝试将 RKRequestDelegate 类作为委托(delegate)添加到我的 View Controller 之一,但该委托(delegate)不存在。我也缺少 RKRequest 类。我查看了硬盘驱动器上的 RestKit 文件夹,但在那里看不到它们。也许我在这个过程中错过了一步。如果其他人遇到过这个问题,那么很高兴听到解决方案。
谢谢布莱恩
最佳答案
这是一个关于从 0.10.x 升级到 0.20.0 的 wiki:
https://github.com/RestKit/RestKit/wiki/Upgrading-from-v0.10.x-to-v0.20.0
如你所见,真的是一个很大的变化。对于 RKRequestDelegate
,正如它所说:
The delegate protocols RKRequestDelegate and RKObjectLoaderDelegate have been removed from the project in favor of block based approaches. The most common, required methods of these protocols such as request:didLoadResponse:, request:didLoadError:, objectLoader:didLoadObjects:, and objectLoader:didLoadError: have been replaced with completion blocks on the AFHTTPRequestOperation and RKObjectRequestOperation classes. In general, these completion blocks are specified as a pair of success and failure blocks
看起来很棘手..
关于ios - RestKit - RKRequestDelegate 不存在,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14159851/
我已经将 RestKit 安装到 Xcode 中并且构建良好。但是,我似乎在很多课上都不见了。我正在尝试将 RKRequestDelegate 类作为委托(delegate)添加到我的 View Co
我正在实现 -(void)request:(RKRequest *)request didReceivedData:(NSInteger)bytesReceived totalBytesReceive
我是一名优秀的程序员,十分优秀!