---
title: insertedObjects
framework: coredata
role: symbol
role_heading: Instance Property
path: coredata/nsmanagedobjectcontext/insertedobjects
---

# insertedObjects

The set of objects that have been inserted into the context but not yet saved in a persistent store.

## Declaration

```swift
var insertedObjects: Set<NSManagedObject> { get }
```

## Discussion

Discussion A managed object context does not post key-value observing notifications when the return value of insertedObjects changes—it does, however, post a NSManagedObjectContextObjectsDidChange notification when a change is made, and a NSManagedObjectContextWillSave and a NSManagedObjectContextDidSave notification before and after changes are committed respectively.

## See Also

### Related Documentation

- [registeredObjects](coredata/nsmanagedobjectcontext/registeredobjects.md)

### Handling managed objects

- [shouldDeleteInaccessibleFaults](coredata/nsmanagedobjectcontext/shoulddeleteinaccessiblefaults.md)
- [updatedObjects](coredata/nsmanagedobjectcontext/updatedobjects.md)
- [deletedObjects](coredata/nsmanagedobjectcontext/deletedobjects.md)
- [shouldHandleInaccessibleFault(_:for:triggeredByProperty:)](coredata/nsmanagedobjectcontext/shouldhandleinaccessiblefault(_:for:triggeredbyproperty:).md)
- [insert(_:)](coredata/nsmanagedobjectcontext/insert(_:).md)
- [delete(_:)](coredata/nsmanagedobjectcontext/delete(_:).md)
- [assign(_:to:)](coredata/nsmanagedobjectcontext/assign(_:to:).md)
- [obtainPermanentIDs(for:)](coredata/nsmanagedobjectcontext/obtainpermanentids(for:).md)
- [detectConflicts(for:)](coredata/nsmanagedobjectcontext/detectconflicts(for:).md)
- [refresh(_:mergeChanges:)](coredata/nsmanagedobjectcontext/refresh(_:mergechanges:).md)
- [processPendingChanges()](coredata/nsmanagedobjectcontext/processpendingchanges().md)
- [observeValue(forKeyPath:of:change:context:)](coredata/nsmanagedobjectcontext/observevalue(forkeypath:of:change:context:).md)
