I am new to iPhone development. I am developing an iPhone application which needs to open files stored on Amazon's S3 service.
How do I download a file from S3 to my iPhone application? I have tried Amazon's SDK, but they don't seem to provide a means of downloading and saving a file. How do I go about obtaining a file's URL from S3 and saving it in my application?
I always use the ASIHttpRequest library to do this and it's quite simple, here's a sample code from their website:
You can't get easier than this :)
If you don't have the luxury of simplicity using ASI, and/or are stuck with AWSiOS SDK, it's not a lot different:
Then you can look at
downloadResponse.body
anddownloadResponse.httpStatusCode
, preferable in a delegate: