-
Notifications
You must be signed in to change notification settings - Fork 20
Dispatcher
aleclarson edited this page Oct 21, 2014
·
1 revision
Dispatcher
holds references to all pre-made queues and allows you to make your own Queue
s.
It is also a concurrent queue for default-priority tasks.
You can access Dispatcher
through the gcd
global constant.
gcd.main
: The serial queue for the user interface. Learn more about the main queue.
gcd.high
: The concurrent queue for high-priority tasks.
gcd.low
: The concurrent queue for low-priority tasks.
gcd.background
: The concurrent queue for zero-priority tasks.
You must retain any Queue
s you create!
let serialQueue = gcd.serial()
let concurrentQueue = gcd.concurrent()