Initializer

init()

Creates a new group to which you can assign block objects.

Declaration

init()

Return Value

The newly created group.

Discussion

This function creates a new group with which block objects can be associated (by using the dispatch_group_async(_:_:_:) function). The dispatch group maintains a count of its outstanding associated tasks, incrementing the count when a new task is associated and decrementing it when a task completes. Functions such as notify(queue:execute:) and dispatch_group_wait(_:_:) use that count to allow your application to determine when all tasks associated with the group have completed. At that time, your application can take any appropriate action.