org.rococoa.cocoa.foundation.categories
Interface NSURLConnectionDelegate

All Superinterfaces:
ObjCObject

public interface NSURLConnectionDelegate
extends ObjCObject


Nested Class Summary
static interface NSURLConnectionDelegate._static_
           
 
Method Summary
 boolean connection_canAuthenticateAgainstProtectionSpace(NSURLConnection connection, NSURLProtectionSpace protectionSpace)
           
 void connection_didCancelAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)
           
 void connection_didFailWithError(NSURLConnection connection, NSError error)
           
 void connection_didReceiveAuthenticationChallenge(NSURLConnection connection, NSURLAuthenticationChallenge challenge)
           
 void connection_didReceiveData(NSURLConnection connection, NSData data)
           
 void connection_didReceiveResponse(NSURLConnection connection, NSURLResponse response)
           
 void connection_didSendBodyData_totalBytesWritten_totalBytesExpectedToWrite(NSURLConnection connection, NSInteger bytesWritten, NSInteger totalBytesWritten, NSInteger totalBytesExpectedToWrite)
           
 NSInputStream connection_needNewBodyStream(NSURLConnection connection, NSURLRequest request)
           
 NSCachedURLResponse connection_willCacheResponse(NSURLConnection connection, NSCachedURLResponse cachedResponse)
           
 NSURLRequest connection_willSendRequest_redirectResponse(NSURLConnection connection, NSURLRequest request, NSURLResponse response)
           
 void connectionDidFinishLoading(NSURLConnection connection)
           
 boolean connectionShouldUseCredentialStorage(NSURLConnection connection)
           
 
Methods inherited from interface org.rococoa.ObjCObject
id
 

Method Detail

connection_willSendRequest_redirectResponse

NSURLRequest connection_willSendRequest_redirectResponse(NSURLConnection connection,
                                                         NSURLRequest request,
                                                         NSURLResponse response)
Parameters:
connection - an NSURLConnection that has determined that it
must change URLs in order to continue loading a request.
request - The NSURLRequest object that will be used to
continue loading. The delegate should copy and modify this request
as necessary to change the attributes of the request, or can
simply return the given request if the delegate determines that no
changes need to be made.
redirectResponse - The NSURLResponse that caused this
callback to be sent. This argument is nil in cases where this
callback is not being sent as a result of involving the delegate
in redirect processing.

connection_needNewBodyStream

NSInputStream connection_needNewBodyStream(NSURLConnection connection,
                                           NSURLRequest request)
Parameters:
connection - an NSURLConnection that has determined that it
required a new body stream to continue.
request - The current NSURLRequest object associated with the connection.

connection_canAuthenticateAgainstProtectionSpace

boolean connection_canAuthenticateAgainstProtectionSpace(NSURLConnection connection,
                                                         NSURLProtectionSpace protectionSpace)
Parameters:
connection - an NSURLConnection that has an NSURLProtectionSpace ready for inspection
protectionSpace - an NSURLProtectionSpace that will be used to generate an authentication challenge

connection_didReceiveAuthenticationChallenge

void connection_didReceiveAuthenticationChallenge(NSURLConnection connection,
                                                  NSURLAuthenticationChallenge challenge)
Parameters:
connection - the connection for which authentication is needed
challenge - The NSURLAuthenticationChallenge to start authentication for
Original signature : -(void)connection:(NSURLConnection*) didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge*)
from NSURLConnectionDelegate native declaration : NSURLConnection.h:301

connection_didCancelAuthenticationChallenge

void connection_didCancelAuthenticationChallenge(NSURLConnection connection,
                                                 NSURLAuthenticationChallenge challenge)
Parameters:
connection - the connection for which authentication was cancelled
challenge - The NSURLAuthenticationChallenge for which to cancel authentication
Original signature : -(void)connection:(NSURLConnection*) didCancelAuthenticationChallenge:(NSURLAuthenticationChallenge*)
from NSURLConnectionDelegate native declaration : NSURLConnection.h:309

connectionShouldUseCredentialStorage

boolean connectionShouldUseCredentialStorage(NSURLConnection connection)
Parameters:
connection - the NSURLConnection object asking if it should consult the credential storage.

connection_didReceiveResponse

void connection_didReceiveResponse(NSURLConnection connection,
                                   NSURLResponse response)
Parameters:
connection - an NSURLConnection instance for which the
NSURLResponse is now available.
response - the NSURLResponse object for the given
NSURLConnection.
Original signature : -(void)connection:(NSURLConnection*) didReceiveResponse:(NSURLResponse*)
from NSURLConnectionDelegate native declaration : NSURLConnection.h:342

connection_didReceiveData

void connection_didReceiveData(NSURLConnection connection,
                               NSData data)
Parameters:
connection - NSURLConnection that has received data.
data - A chunk of URL load data.
Original signature : -(void)connection:(NSURLConnection*) didReceiveData:(NSData*)
from NSURLConnectionDelegate native declaration : NSURLConnection.h:362

connection_didSendBodyData_totalBytesWritten_totalBytesExpectedToWrite

void connection_didSendBodyData_totalBytesWritten_totalBytesExpectedToWrite(NSURLConnection connection,
                                                                            NSInteger bytesWritten,
                                                                            NSInteger totalBytesWritten,
                                                                            NSInteger totalBytesExpectedToWrite)
Parameters:
connection - NSURLConnection that has written data.
bytesWritten - number of bytes written
totalBytesWritten - total number of bytes written for this connection
totalBytesExpectedToWrite - the number of bytes the connection expects to write (can change due to retransmission of body content)
Original signature : -(void)connection:(NSURLConnection*) didSendBodyData:(NSInteger) totalBytesWritten:(NSInteger) totalBytesExpectedToWrite:(NSInteger)
from NSURLConnectionDelegate native declaration : NSURLConnection.h:381

connectionDidFinishLoading

void connectionDidFinishLoading(NSURLConnection connection)
Parameters:
connection - an NSURLConnection that has finished loading
successfully.
Original signature : -(void)connectionDidFinishLoading:(NSURLConnection*)
from NSURLConnectionDelegate native declaration : NSURLConnection.h:393

connection_didFailWithError

void connection_didFailWithError(NSURLConnection connection,
                                 NSError error)
Parameters:
connection - an NSURLConnection that has failed to load.
error - The error that encapsulates information about what
caused the load to fail.
Original signature : -(void)connection:(NSURLConnection*) didFailWithError:(NSError*)
from NSURLConnectionDelegate native declaration : NSURLConnection.h:406

connection_willCacheResponse

NSCachedURLResponse connection_willCacheResponse(NSURLConnection connection,
                                                 NSCachedURLResponse cachedResponse)
Parameters:
connection - an NSURLConnection that has a NSCachedURLResponse
ready for inspection.


Copyright © 2009. All Rights Reserved.