ios - How does NSURLConnection gives callback on the same thread? -


how nsurlconnection asynchronous request gives callbacks on same thread called from?

if have design worker class take work off calling thread , when done give completion callback on same thread called from, how that?

typedef void (^basictask)(void);  @protocol workerdelegate - (void)taskdidsucceed; - (void)taskdidfailwitherror:(nsstring *)errordescription; @end  @interface worker {     id <workerdelegate> delegate; } -(void)performtaskinbackground:(basictask)task; @end 


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

keyboard - C++ GetAsyncKeyState alternative -

android - java.net.UnknownHostException(Unable to resolve host “URL”: No address associated with hostname) -