On Jul 28, 2009, at 12:07 AM, Debajit Adhikary <deba...@debajit.com> wrote:

- Is it possible that more than two connections will use the delegate at
  the same time? (I would think so)

Asynchronous does not always mean your callbacks are invoked on another thread -- or that threads are even involved at all. The system can synchronously dispatch the HTTP connection, ad itself as an input source to the current runloop, and return to your code, firing at the appropriate time.

Since the documentation states that callbacks are called on the same thread as the asynchronous call is made, two can't execute at once (as long as all your connections are made on the same thread).

  - If yes, how is it resolved? (Does Cocoa do this automatically?)

Re-read the run loops documentation and then the NSURLConnection documentation again.

--Kyle Sluder
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to