Question

Currently working with NSURLConnection. Found a great website showing important delegate methods coming with NSURLConnection class (http://cocoawithlove.com/2011/05/classes-for-fetching-and-parsing-xml-or.html)

- (void)connection:(NSURLConnection *)connection didReceiveResponse:(NSURLResponse *)response
- (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data
- (void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error
- (void)connectionDidFinishLoading:(NSURLConnection *)connection

I can't find these methods explained in Apple's:

  • NSURLConnection Class Reference
  • NSURLConnectionDelegate Protocol Reference
  • NSURLConnectionDownloadDelegate Protocol Reference

The methods Apple only explain in the system guide: Using NSURLConnection. Since the methods belong to NSURLConnection why is there no easy way to look them up in NSURLConnectionDelegate Protocol Reference? Please help me to finally understand Apple's documentation.

Was it helpful?

Solution

Look in the documentation and in the NSURLConnection.h file for the NSURLConnectionDataDelegate protocol. Those methods along with those still documented in the NSURLConnectionDelegate class are the methods that may get called on your delegate.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top