On Mar 21, 2011, at 10:24 PM, Chris Hanson wrote: > Ultimately, the solution will be to modify HessianKit -- or any other > framework that presents an RPC-style interface[1] -- to follow the Cocoa > convention of returning BOOL (or a non-nil/nil object reference) to indicate > success or failure, and to fill in an NSError passed by reference if the > caller desires additional failure details. > > -- Chris > > [1] Distributed Objects doesn’t work this way - it predates NSError and uses > exceptions, which results in exactly the problems discussed in this thread. > Often DO calls will wind up wrapped in an API that just does a @try/@catch > around the call and returns success/failure, for exactly this reason.
Hi Chris, I am curious as to how you would propose to add error: handlers to DO calls considering that DO is meant to transparent and cannot modify method signatures. For example, assuming you were designing a new DO framework, how would you propose changing this: int junk = [secretlyDistantObject calculate:4]; to allow for a socket timeout? Would you then wrap any API which could be potentially called by DO with the additional error: argument? Cheers, M_______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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/archive%40mail-archive.com This email sent to arch...@mail-archive.com