I am new to the concept of NSURLSession
. Now I am working on the sample on NSURLSession
. I read so many answers about the difference between them but I didn't understand clearly.Can any one please tell me the difference between them with simple example.
Asked
Active
Viewed 6,406 times
1

Bhavin Ramani
- 3,221
- 5
- 30
- 41

anusha hrithi
- 709
- 2
- 9
- 13
-
you can get difference of both perfectly from this http://code.tutsplus.com/tutorials/networking-with-nsurlsession-part-1--mobile-21394 – Bhavin Ramani Apr 07 '16 at 06:38
-
Have a look at this https://www.objc.io/issues/5-ios7/from-nsurlconnection-to-nsurlsession/ – Ruchira Randana Apr 07 '16 at 06:51
1 Answers
3
NSURLConnection is a much older API, introduced in OS X 10.2.
NSURLSession was introduced in OS X 10.9, and has a more modern (task- and block-based) API. It is the successor to NSURLConnection, and you should use it in all new projects.
This objc.io post has more information about the two.

jtbandes
- 115,675
- 35
- 233
- 266