今天在看NSURLConnection
类,具体研究方法:
- (void) connection: (NSURLConnection *) conn didFailWithError:(NSError *)error {
事实证明它已被弃用。 文档似乎没有提供关于替换此方法的提示。请问我该如何继续寻找它?
最佳答案
在大多数情况下,弃用通知包括替换方法。参见 Deprecated UITableViewDelegate Methods和 Deprecated NSFileManager Methods举个例子。在这种情况下,文档有点困惑,您应该让文档编写者知道这一点。在web page的底部有一个地方可以提供反馈。
正如其他响应者所指出的,这里几乎没有实际变化,因为他们只是将旧的非正式协议(protocol)转变为正式协议(protocol)。但是文档具有误导性,他们应该修复它。
这是我发送的反馈的副本:
This page gives the impression that you shouldn't use these methods anymore. In fact, you should, but they've been moved to a formal protocol. This should be stated more clearly in the deprecation notice.
关于objective-c - 弃用的方法,寻找替代方法,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8313235/