In this recipe, we will learn about the different methods that can be used to store and use documents within iCloud.
In this section, we will learn about the file coordinator and the file presenter classes and how the
UIDocument class can be registered to receive updates whenever the iCloud data gets updated.
The following example shows how to use the
myDocument = [[myDocument alloc] initWithFileURL:ubiquityURL]; myDocument.delegate = self; coordinator = [[NSFileCoordinator alloc] initWithFilePresenter:myDocument]; [NSFileCoordinator addFilePresenter:myDocument];
The job of a file coordinator is to coordinate the reads and writes performed by your application ...