---
title: removeAllObjects()
framework: foundation
role: symbol
role_heading: Instance Method
path: foundation/nsmutableset/removeallobjects()
---

# removeAllObjects()

Empties the set of all of its members.

## Declaration

```swift
func removeAllObjects()
```

## See Also

### Related Documentation

- [minus(_:)](foundation/nsmutableset/minus(_:).md)
- [intersect(_:)](foundation/nsmutableset/intersect(_:).md)

### Adding and removing entries

- [add(_:)](foundation/nsmutableset/add(_:).md)
- [filter(using:)](foundation/nsmutableset/filter(using:).md)
- [remove(_:)](foundation/nsmutableset/remove(_:).md)
- [addObjects(from:)](foundation/nsmutableset/addobjects(from:).md)
