CallbackQueue
public enum CallbackQueue
Callback queue behaviors when a closure call is dispatched.
- asyncMain: Dispatches a call to
DispatchQueue.mainwith theasyncbehavior. - currentMainOrAsync: Dispatches a call to
DispatchQueue.mainwith theasyncbehavior if the current queue is not.main. Otherwise, calls a closure immediately in the main queue. - untouch: Does not change a call queue for a closure.
- dispatch: Dispatches a call to a specified
DispatchQueueobject. - operation: Uses a specified
OperationQueueobject and adds a closure to the operation queue.
-
Dispatches a call to
DispatchQueue.mainwith theasyncbehavior.Declaration
Swift
case asyncMain -
Dispatches a call to
DispatchQueue.mainwith theasyncbehavior if the current queue is not.main. Otherwise, calls a closure immediately in the main queue.Declaration
Swift
case currentMainOrAsync -
Does not change a call queue for a closure.
Declaration
Swift
case untouch -
Dispatches a call to a specified
DispatchQueueobject.Declaration
Swift
case dispatch(DispatchQueue) -
Uses a specified
OperationQueueobject and adds a closure to the operation queue.Declaration
Swift
case operation(OperationQueue)
View on GitHub
CallbackQueue Enumeration Reference