Core Data Backups, Redux
[]
The Atomic Birdhouse
In essence it loops through all current persistent stores and does a replace for each one, creating a backup copy with the same options and store type. Tell the persistent store to replace the current store’s URL with data from the backup URL. The core of that is just a replace call where the source is the backup store URL and the destination is the URL of the store we’re already using.