Reputation: 490
I want to create a iPhone chat application and i do not have any experience of socket programming so can u please help me understand How can i do long polling from iPhone application?
Also can NSURLConnection be used for this purpose or we need to use some low level API?
Are there any libraries available for the same?
Upvotes: 1
Views: 1634
Reputation: 53669
Long polling is for languages like javascript that cannot open persistent connections. You can still do long polling with something like NSURLConnection, but you would be much better served by CFStreamCreatePairWithSocketToHost or similar to open a full bidirectional socket.
Long polling is basically a hack that has become a buzzword.
Upvotes: 2