开发者

Objective-C++ and UDP

Is there an alternative to cocoaasyncsocket written in Objective-C++? Or is it easy to convert? I need to use an UDP library for iPhone Objective-C开发者_运维百科++.


Take a look at Networking & Internet Starting Point and CFNetwork Programming Guide from Apple docs


Converting valid Objective-C files to Objective-C++ is easier than 1,2,3; Simply rename all *.m files to *.mm and you are done.


What exactly do you mean by Objective-C++? Objective-C or C++?

I would look into Apple's CoreFoundation first, which is available for OS X and iOS. There is all you need for doing networking. For example there is a CFSocket class, which should be sufficient to use UDP.

CoreFoundation is implemented in C, so it should be easy to use it from Obj-C or C++ code.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜