Network Programming
What's the recommended networking api on OSX? Cocoa excluded, I've looked at OpenTransport and CFNetwork and the docs are appalling for both. What is everyone else using?
I used Open Transport when I had to use networking. Apple's Carbon documentation for it is HORRIBLE, but you can still get Inside Macintosh: Open Transport from the Classic section. Quite a good book but only covers up to Open Transport 1.3.
Inside Macintosh: Open Transport, the O.T. technotes and looking up stuff on XTI ( what Open Transport was based on ) managed to do the trick for me
~~
You could also just try using BSD Sockets itself. From what I understand, they have somewhat better performance than Open Transport( which on OS X is just a wrapper on top of BSD Sockets )
check here for a page on BSD Sockets : http://www.ecst.csuchico.edu/~beej/guide/net/html/
Inside Macintosh: Open Transport, the O.T. technotes and looking up stuff on XTI ( what Open Transport was based on ) managed to do the trick for me

~~
You could also just try using BSD Sockets itself. From what I understand, they have somewhat better performance than Open Transport( which on OS X is just a wrapper on top of BSD Sockets )
check here for a page on BSD Sockets : http://www.ecst.csuchico.edu/~beej/guide/net/html/
And since the BSD socket API is cross-platform and has been around for decades, there are way more tutorials and open-source specialty wrappers and so on for them than for pretty much everything else.
Just go with sockets; your code will be more portable and the docs are good 
It's not really all that hard, either.
The best tutorial I've seen: http://www.ecst.csuchico.edu/~beej/guide/net/

It's not really all that hard, either.
The best tutorial I've seen: http://www.ecst.csuchico.edu/~beej/guide/net/
I've done sockets before. I was hoping to find 'the one true OS X way' but I'm not having any luck. CFNetwork seems to be a wrapper for sockets but there are NO docs at all.
The ideal would be a class library that works just like Java's networking stuff. I've just spent the last 2 hours playing with Java and I have a working newsgroup reader. It's just a shame java still looks ugly on OS X.
The ideal would be a class library that works just like Java's networking stuff. I've just spent the last 2 hours playing with Java and I have a working newsgroup reader. It's just a shame java still looks ugly on OS X.
maybe you might want to try using distributed objects http://developer.apple.com/techpubs/maco...index.html
I used Java in the end. Way easier. Apple should ditch Cocoa and concentrate on Java.
Quote:Originally posted by henryj
I've done sockets before. I was hoping to find 'the one true OS X way' but I'm not having any luck. CFNetwork seems to be a wrapper for sockets but there are NO docs at all.
"The one true" Mac OS X way (excluding Cocoa) is to use CFNetwork. I would suggest these over sockets, especially if you want to tap into things like Rendezvous. But if you don't need the extras, just use sockets (that's what I do
)Cheers,
Rocco
Virus Out
Big Bang Board Games
Adventures on Pirate Isle
Solace - Strategy, War, and Glory!
The Belt
Possibly Related Threads...
| Thread: | Author | Replies: | Views: | Last Post | |
| java network api | San_Andreas | 1 | 2,865 |
May 1, 2008 08:05 AM Last Post: AndyKorth |
|
| Getting network connection for a specified PID | Florian | 6 | 4,497 |
Dec 23, 2006 03:46 AM Last Post: Florian |
|
| Ways to Network. | BinarySpike | 28 | 11,706 |
May 10, 2005 07:44 PM Last Post: kodex |
|
| Network Code Design | Bachus | 5 | 4,212 |
Sep 26, 2004 06:54 PM Last Post: arcnon |
|
| Network Servers - whose connected to me? | Zenith | 3 | 4,274 |
Oct 2, 2003 04:29 PM Last Post: Steven |
|

