Interface NSURLConnectionDelegate
-
- All Known Subinterfaces:
NSURLConnectionDataDelegate,NSURLConnectionDownloadDelegate
public interface NSURLConnectionDelegate[@protocol] NSURLConnectionDelegate Delegate methods that are common to all forms of NSURLConnection. These are all optional. This protocol should be considered a base class for the NSURLConnectionDataDelegate and NSURLConnectionDownloadDelegate protocols. connection:didFailWithError: will be called at most once, if an error occurs during a resource load. No other callbacks will be made after.connectionShouldUseCredentialStorage: will be called at most once, before a resource load begins (which means it may be called during construction of the connection.) The delegate should return TRUE if the connection should consult the shared NSURLCredentialStorage in response to authentication challenges. Regardless of the result, the authentication challenge methods may still be called. connection:willSendRequestForAuthenticationChallenge: is the preferred (Mac OS X 10.7 and iOS 5.0 or later) mechanism for responding to authentication challenges. See
for more information on dealing with the various types of authentication challenges. connection:canAuthenticateAgainstProtectionSpace: connection:didReciveAuthenticationChallenge: connection:didCancelAuthenticationChallenge: are deprected and new code should adopt connection:willSendRequestForAuthenticationChallenge. The older delegates will still be called for compatability, but incur more latency in dealing with the authentication challenge.
-
-
Method Summary
All Methods Instance Methods Default Methods Deprecated Methods Modifier and Type Method Description default booleanconnectionCanAuthenticateAgainstProtectionSpace(NSURLConnection connection, NSURLProtectionSpace protectionSpace)Deprecated.default voidconnectionDidCancelAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)Deprecated.default voidconnectionDidFailWithError(NSURLConnection connection, NSError error)default voidconnectionDidReceiveAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)Deprecated.default booleanconnectionShouldUseCredentialStorage(NSURLConnection connection)default voidconnectionWillSendRequestForAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)
-
-
-
Method Detail
-
connectionCanAuthenticateAgainstProtectionSpace
@Deprecated default boolean connectionCanAuthenticateAgainstProtectionSpace(NSURLConnection connection, NSURLProtectionSpace protectionSpace)
Deprecated.
-
connectionDidCancelAuthenticationChallenge
@Deprecated default void connectionDidCancelAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)
Deprecated.
-
connectionDidFailWithError
default void connectionDidFailWithError(NSURLConnection connection, NSError error)
-
connectionDidReceiveAuthenticationChallenge
@Deprecated default void connectionDidReceiveAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)
Deprecated.
-
connectionWillSendRequestForAuthenticationChallenge
default void connectionWillSendRequestForAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)
-
connectionShouldUseCredentialStorage
default boolean connectionShouldUseCredentialStorage(NSURLConnection connection)
-
-