• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to fetch remote file?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


References: 
 >How to fetch remote file? (From: "parag vibhute" <email@hidden>)
 >Re: How to fetch remote file? (From: Mike Abdullah <email@hidden>)
 >Re: How to fetch remote file? (From: Chris Suter <email@hidden>)

  • Prev by Date: Re: How to fetch remote file?
  • Next by Date: App fails to kill NSTask processes
  • Previous by thread: Re: How to fetch remote file?
  • Next by thread: Re: How to fetch remote file?
  • Index(es):
    • Date
    • Thread