mtigas/iOS-MapLayerDemo — pull request #4 by timothyarnold (2012-03-23 05:35:48+00:00)
Title: Remove dependency on third party code

I've modified the project a little bit so that tile caching is done using only built-in iOS functionality.

I used the code for a while, keeping Three20, and ran into headache after headache trying to get it to incorporate into my project without error. (It works out of the box with this project, but as I changed the project, wanted to Archive to an IPA, etc., I ran into trouble).

I wanted to find another simpler solution, and came up with what's included in this fork. It makes asynchronous HTTP requests using NSURLConnection's sendAsynchronousRequest:queue:completionHandler: method, and stores the cached images in NSTemporaryDirectory(), which sticks around for a few days (I think).

Incorporate the changes if you like. I haven't tested the performance side by side, but this solution seems to work okay, and it greatly simplifies the code.

Thanks for the original project, it was incredibly useful to me!