Does performSelectorInBackground execute a new thread for each call?

Does it create a performSelectorInBackgroundnew thread for each call or share a thread (which is not the main thread) for all calls (maybe queued)?

+3
source share
1 answer

A new thread is created with every call. -performSelectorInBackground:withObject:

From Thread Programming Guide

Using NSObject to create a stream

iOS Mac OS X v10.5 . performSelectorInBackground: withObject: . , ( myObj), , doSomething, , :

[myObj performSelectorInBackground:@selector(doSomething) withObject:nil];

, detachNewThreadSelector: toTarget: withObject: NSThread , . . , . , ( ) , . . " ".

+11

Source: https://habr.com/ru/post/1785348/


All Articles