views:

227

answers:

2

Hi,

I've read the Core Data references on Apple's site. But I wonder, what they mean with atomic store types? They write something of "they have to be read and written in their entirety".

Could somebody clarify this, please?

+3  A: 

Atomicity refers to the property of an entire operation happening before another operation can interrupt it-i.e. for that thread an "atomic" operation will complete if started. In real life this usually means checking the value of something at the start and end of an operation, and if that value changed apart from what the atomic operation performed re-attempt the operation.

Specifically, in the case of Core Data, the atomic stores are formats where the entire store file must be written out with every change, as opposed to SQLite, where only the changes are written to the database on disk.
Brad Larson
+1  A: 

It means that they cannot be in a state where they are half-written.

Andreas Bonini