Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CFURLDestroyResource is now deprecated in iOS7. What to use instead?

CFURLDestroyResource is now deprecated. I am unsure what to use instead of it though, and haven't had any luck digging through Apple's documentation.

I am using BlackRaccoon to manipulate my FTP server and it makes use of CFURLDestroyResource which is of course now causing a compiler warning.

like image 687
Scooter Avatar asked Nov 24 '13 19:11

Scooter


1 Answers

We also ran into this issue and couldn't find any alternative within Apple's framework; in CFURLAccess.h, Apple recommends using NSURLConnection, but I could not find a way to perform deletions with said class. It would also seem that most third-party libraries make use of CFURLDestroyResource as well.

Then we unearthed this: https://github.com/nkreipke/FTPManager. This FTPManager leverages the fact that Objective-C is a strict superset of C and performs the FTP operations by creating the raw sockets and simply writing the commands manually. It is a method that may be a bit "nuts and bolts" for developers who are accustomed to high-level solutions, but it's elegant in its minimalism and efficiency. And when you get right down to it, most other FTP frameworks are probably executing commands such as these at some level anyway.

like image 69
JavaSplice Avatar answered Oct 10 '22 09:10

JavaSplice