Re: Cocoa and Sockets
Re: Cocoa and Sockets
- Subject: Re: Cocoa and Sockets
- From: Douglas Davidson <email@hidden>
- Date: Mon, 9 Jun 2003 09:30:45 -0700
On Monday, June 9, 2003, at 5:02 AM, Adam wrote:
Here come serious questions. I would like to add BSD
socket to my Cocoa application, so:
1. What kind of API should I use / you recommend:
a) NSSocketPort
b) CoreFoundation
c) UNIX/BSD
2. How can I receive events from sockets? Means, how
the application can be interrupted when data arrives
to the socket? Can I method be invoked, as an Action?
I'm not going to try to tell you what networking APIs you should
use--there are flavors for every persuasion--but I just want to say
right off the bat that NSSocketPort is not a general socket class.
Instead, it is an NSPort subclass based on BSD sockets--that means it's
part of the machinery of distributed objects. The thing in Cocoa that
corresponds most closely to a general socket class is CFSocket; then
CFNetwork adds higher-level stream abstractions on top of that.
Douglas Davidson
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.