NuHTTP Class Reference

NuHTTPClient

Superclass: NSObject
Declared in: nu/client.nu

A simple HTTP client for downloading URLs.

Methods

- (void) beginDownloadingURL: (id) urlString
Begin downloading a url (specified by a string).

in nu/client.nu

- (void) connection: (id) connection
didFailWithError: (id) error
This delegate method handles connection failures. It is for internal use only.

in nu/client.nu

- (void) connection: (id) connection
didReceiveAuthenticationChallenge: (id) challenge
This delegate method handles HTTP authentication challenges. To prepare a response, set the credential instance variable to an instance of NSURLCredential. It is for internal use only.

in nu/client.nu

- (void) connection: (id) connection
didReceiveData: (id) data
This delegate method accepts data as it is received. It is for internal use only.

in nu/client.nu

- (void) connection: (id) connection
didReceiveResponse: (id) response
This delegate method handles a response when it is received.

in nu/client.nu

- (void) connectionDidFinishLoading: (id) connection
This delegate method handles the completion of a connection. It is for internal use only.

in nu/client.nu

- (void) flushURL: (id) url
Remove the result for a specified url from the cache.

in nu/client.nu

- (id) freshResourceForURL: (id) url
Download a resource after flushing its previous value from the cache.

in nu/client.nu

- (id) init
Create a client with the user agent "NuHTTPClient".

in nu/client.nu

- (id) initWithUserAgent: (id) userAgent
Create a client with the specified name as its user agent. If userAgent is nil, default to "NuHTTPClient".

in nu/client.nu

- (id) resourceForURL: (id) url
Synchronously download a possibly-cached resource.

in nu/client.nu

- (void) waitForDownloadToComplete
Call this method to synchronously wait for a download to complete.

in nu/client.nu