---
title: atomic
framework: foundation
role: symbol
role_heading: Type Property
path: foundation/nsdata/writingoptions/atomic
---

# atomic

An option to write data to an auxiliary file first and then replace the original file with the auxiliary file when the write completes.

## Declaration

```swift
static var atomic: NSData.WritingOptions { get }
```

## Discussion

Discussion This option is equivalent to using a write method that takes the parameter atomically as true.

## See Also

### Constants

- [withoutOverwriting](foundation/nsdata/writingoptions/withoutoverwriting.md)
- [noFileProtection](foundation/nsdata/writingoptions/nofileprotection.md)
- [completeFileProtection](foundation/nsdata/writingoptions/completefileprotection.md)
- [completeFileProtectionUnlessOpen](foundation/nsdata/writingoptions/completefileprotectionunlessopen.md)
- [completeFileProtectionUntilFirstUserAuthentication](foundation/nsdata/writingoptions/completefileprotectionuntilfirstuserauthentication.md)
- [fileProtectionMask](foundation/nsdata/writingoptions/fileprotectionmask.md)
- [completeFileProtectionWhenUserInactive](foundation/nsdata/writingoptions/completefileprotectionwhenuserinactive.md)
