FROM : William Zumwalt
DATE : Sat Jan 05 02:54:07 2008
Then what's the point of using ports to communicate over if I went to using
performSelectorInMainThread? Besides, I'm going from the client (main
thread) to the server (NSThread).
Maybe I'm doing something all wrong, but my code is very, very similar to
what's in the apple thread communication docs.
On Jan 4, 2008 7:48 PM, John Stiles <<email_removed>> wrote:
> -performSelectorInMainThread: certainly predates Leopard…? I distinctly
> remember using it back in the 10.2/10.3 days.
>
>
> marcelo.<email_removed> wrote:
> >>
> >> However my problem now is that with all three marked as (oneway void)
> >> (sending async msgs), message #2 requires a few seconds to complete
> >> while
> >> message #3 depends on message #2 before it can start, yet msg #3 is
> done
> >> before msg #2 can finish. I've also seen once where they arrived out of
> >> order.
> >>
> >>
> >> // from the client
> >>
> >> [server sendMsg1];
> >>
> >> [server sendMsg2];
> >>
> >> [server sendMsg3];
> >>
> >>
> >> Is there another way to call asynchronously, yet guarantee that the
> >> messages
> >> arrive in order? Or someway to call w/o the GUI blocking for a server
> >> message return?
> >
> >
> > You can use :
> > - NSConnection/NSPorts (
> >
> http://developer.apple.com/documentation/Cocoa/Conceptual/Multithreading/articles/SocketComm.html#//apple_ref/doc/uid/TP40001479
> > )
> > - YAMessageQueue (10.4-):
> http://www.2pi.dk/tech/cocoa/message_queue.html
> > - NSOperation/NSOperationQueue (10.5+) :
> > - [NSObject performSelector:onThread]/[NSObject
> > performSelectorInMainThread:] (10.5+);
> >
> >
> > :: marcelo.alves
> > _______________________________________________
> >
> > Cocoa-dev mailing list (<email_removed>)
> >
> > Please do not post admin requests or moderator comments to the list.
> > Contact the moderators at cocoa-dev-admins(at)lists.apple.com
> >
> > Help/Unsubscribe/Update your Subscription:
> > http://lists.apple.com/mailman/options/cocoa-dev/<email_removed>
> >
> > This email sent to <email_removed>
>
DATE : Sat Jan 05 02:54:07 2008
Then what's the point of using ports to communicate over if I went to using
performSelectorInMainThread? Besides, I'm going from the client (main
thread) to the server (NSThread).
Maybe I'm doing something all wrong, but my code is very, very similar to
what's in the apple thread communication docs.
On Jan 4, 2008 7:48 PM, John Stiles <<email_removed>> wrote:
> -performSelectorInMainThread: certainly predates Leopard…? I distinctly
> remember using it back in the 10.2/10.3 days.
>
>
> marcelo.<email_removed> wrote:
> >>
> >> However my problem now is that with all three marked as (oneway void)
> >> (sending async msgs), message #2 requires a few seconds to complete
> >> while
> >> message #3 depends on message #2 before it can start, yet msg #3 is
> done
> >> before msg #2 can finish. I've also seen once where they arrived out of
> >> order.
> >>
> >>
> >> // from the client
> >>
> >> [server sendMsg1];
> >>
> >> [server sendMsg2];
> >>
> >> [server sendMsg3];
> >>
> >>
> >> Is there another way to call asynchronously, yet guarantee that the
> >> messages
> >> arrive in order? Or someway to call w/o the GUI blocking for a server
> >> message return?
> >
> >
> > You can use :
> > - NSConnection/NSPorts (
> >
> http://developer.apple.com/documentation/Cocoa/Conceptual/Multithreading/articles/SocketComm.html#//apple_ref/doc/uid/TP40001479
> > )
> > - YAMessageQueue (10.4-):
> http://www.2pi.dk/tech/cocoa/message_queue.html
> > - NSOperation/NSOperationQueue (10.5+) :
> > - [NSObject performSelector:onThread]/[NSObject
> > performSelectorInMainThread:] (10.5+);
> >
> >
> > :: marcelo.alves
> > _______________________________________________
> >
> > Cocoa-dev mailing list (<email_removed>)
> >
> > Please do not post admin requests or moderator comments to the list.
> > Contact the moderators at cocoa-dev-admins(at)lists.apple.com
> >
> > Help/Unsubscribe/Update your Subscription:
> > http://lists.apple.com/mailman/options/cocoa-dev/<email_removed>
> >
> > This email sent to <email_removed>
>
| Related mails | Author | Date |
|---|---|---|
| William Zumwalt | Jan 5, 02:06 | |
| marcelo.alves | Jan 5, 02:38 | |
| John Stiles | Jan 5, 02:48 | |
| William Zumwalt | Jan 5, 02:49 | |
| William Zumwalt | Jan 5, 02:54 | |
| Ken Thomases | Jan 5, 08:36 | |
| James Bucanek | Jan 5, 17:09 | |
| William Zumwalt | Jan 5, 22:35 | |
| William Zumwalt | Jan 5, 22:44 | |
| James Bucanek | Jan 6, 02:35 | |
| James Bucanek | Jan 6, 02:35 | |
| William Zumwalt | Jan 6, 03:35 | |
| glenn andreas | Jan 6, 04:16 | |
| William Zumwalt | Jan 6, 04:25 | |
| James Bucanek | Jan 6, 08:04 | |
| William Zumwalt | Jan 6, 09:28 | |
| Steve Weller | Jan 6, 18:55 |






Cocoa mail archive

