Class

DispatchObject

DispatchObject is the base class for many dispatch types, including DispatchQueue, DispatchGroup, and DispatchSource.

Overview

By default, dispatch objects are declared as Objective-C types when building with an Objective-C compiler. This lets them adopt ARC, enables memory leak checks by the static analyzer, and allows them to be added to Cocoa collections.

Topics

Instance Methods

func activate()

Activates the dispatch object.

func resume()

Resume the invocation of block objects on a dispatch object.

func setTarget(queue: DispatchQueue?)

Sets the target queue for the given object.

func suspend()

Suspends the invocation of block objects on a dispatch object.

See Also

Working with Dispatch Objects

enum DispatchPredicate

DispatchPredicate represents logical conditions that can be evaluated within a given execution context using the dispatchPrecondition(condition:) method.

func dispatchPrecondition(condition: () -> DispatchPredicate)

Checks a dispatch condition necessary for further execution.

func activate()

Activates the dispatch object.