开发者

Thread programming in Objective-C

I am developing a protocol in Objective-C. I am using message queues for transmission. In order to put the data onto the message queue a software routine has to be created to listen to the events. The sender will put the data onto the message queue and will do its other work and will notify the receiver. The receiver then wakes up from the waiting state and calls the software routine and takes up the data.

I don't know how to do this using the Threading methods.

As 开发者_如何转开发the software routine is infinitely waiting for the events to occur does it need to be in an infinite loop? Does it require spinlocks to be implemented?


You should read the docs on the NSStream class.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜