Using an iOS device as a TCP client - no Bonjour

I would like to use the iOS device as a TCP client, but I cannot find a clear API / guide / sample on how to do this. I tried SimpleNetworkStreamsand PictureSharing, but both of them use Bonjour. I can easily make UDP connections by learning through UDPEcho, but I cannot find a good sample UDPEchofor TCP. I want a simple example of connecting to a server and print on the screen all incoming messages from the server - this.

Thank!

+3
source share
2 answers

Have you seen the AsyncSocket project?

http://code.google.com/p/cocoaasyncsocket/

TCP UDP. , googled "cocoa tcp socket class".

: https://github.com/robbiehanson/CocoaAsyncSocket

+5

Bonjour - , tcp/udp.

- tcp udp.

ASIHTTPRequest .


: tcp , Bonjour . . Bonjour.

, google!

+3

Source: https://habr.com/ru/post/1766670/


All Articles