Whenever I load a UIDocument from iCloud, I check its state like so:
NSLog(@"Library loadFromContents: state = %d", self.documentState);
In some cases I have received documentState 8 or 12 which have caused crashes. I am now wondering what exactly the 8 and 12 stands for. As far as I'm aware, documentState is a bit field, so it has many different flags. The docs reveal that:
enum {
UIDocumentStateNormal = 0,
UIDocumentStateClosed = 1 << 0,
UIDocumentStateInConflict = 1 << 1,
UIDocumentStateSavingError = 1 << 2,
UIDocumentStateEditingDisabled = 1 << 3 };
typedef NSInteger UIDocumentState;
However, I have no idea how to interpret this in my situation. How do I find out what 8 and 12 stand for?