Re: How to fetch remote file?
Re: How to fetch remote file?
- Subject: Re: How to fetch remote file?
- From: "I. Savant" <email@hidden>
- Date: Tue, 15 Apr 2008 06:54:40 -0400
NSURLDownload would be the one.
Or you can just use +[NSData dataWithContentsOfURL:].
I'd recommend the previous suggestions. NSURLDownload is non-
blocking and uses callbacks to notify you when the download is
complete (not to mention specific errors and progress). It also
downloads the file to a temporary folder as opposed to loading the
whole thing in memory.
Even if the file is very small, there's no guarantee transmission
won't be interrupted (or will be available at all), which takes time
to time out, etc., blocking all the while.
--
I.S.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden