---
title: "addChild(_:withPendingUnitCount:)"
framework: foundation
role: symbol
role_heading: Instance Method
path: "foundation/progress/addchild(_:withpendingunitcount:)-9yrs3"
---

# addChild(_:withPendingUnitCount:)

Adds a process object as a suboperation of a progress tree.

## Declaration

```swift
func addChild(_ child: Progress, withPendingUnitCount inUnitCount: Int64)
```

## Parameters

- `child`: The progress instance to add to the progress tree.
- `inUnitCount`: The number of units of work for the new suboperation to complete.

## Discussion

Discussion You assign the suboperation a portion of the receiver’s total unit count according to inUnitCount.
