Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS 7: What happened to UIDocument / UIManagedDocument and iCloud?

I was taking a look at WWDC 2013 sessions concerning iCloud and Core Data. I was really hoping to see there any new videos for UIManagedDocument or UIDocument. You might remember that those classes theoretically offer a great and simple approach to save data with (UIManagedDocument) or without CoreData (UIDocument) locally and in iCloud. But there have been or still are some really annoying system-based bugs coming along with those concepts, especially when syncing data between devices, see for example here.

However, there was NO video covering the UIManagedDocument/UIDocument and iCloud topic. The video "What's new in Core Data and iCloud?" just covers the classic approach for using Core Data persistent stores which is extended by new API to automatically cover fallback stores and syncing. Has anyone information what happened to UIManagedDocument/UIDocument? Did they give it up and see the classical approach as the better way to have apps with Core Data and iCloud sync?

like image 341
FrankZp Avatar asked Sep 18 '13 12:09

FrankZp


1 Answers

My understanding is that UIManagedDocument is a lightweight wrapper over core-data to abstract away some of the common core data setup and interactions. It is also a way to package other 'document' elements but managing the iCloud syncing of those items is left as an exercise for the developer.

If you are using iCloud, UIManagedDocument does not support “additional content” in the document directory (see additionalContentForURL:error: and related methods)

That's referenced from: UIManagedDocument

See Also: additionalContentForURL:error:

Pretty much anything that applies to core data applies to UIManagedDocument where it uses core data under the hood. For example I make use of the new fallback stores in my APManagedDocument project.

What kinds of things were you hoping to see added in iOS 7?

like image 139
dtrotzjr Avatar answered Oct 31 '22 07:10

dtrotzjr