Contents

DispatchGroup

A group of tasks that you monitor as a single unit.

Declaration

class DispatchGroup

Overview

Groups allow you to aggregate a set of tasks and synchronize behaviors on the group. You attach multiple work items to a group and schedule them for asynchronous execution on the same queue or different queues. When all work items finish executing, the group executes its completion handler. You can also wait synchronously for all tasks in the group to finish executing.

Topics

Creating a Dispatch Group

Adding a Completion Handler

Waiting for Tasks to Finish Executing

Updating the Group Manually

See Also

Queues and Tasks