If I call invoke
on NSInvocation
, is it the same as calling performSelector:
with the argument waitUntilDone:YES
? That is, does invoke
block the execution until the called selector is done?
In other words, are the two following code lines exactly the same?
// myInvocation is of type NSInvocation
[myInvocation invoke];
[myInvocation performSelectorOnMainThread:@selector(invoke) withObject:nil waitUntilDone:YES];