Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
[ad_1]
I nonetheless fail to know, what’s the downside NSPersistentHistoryTransaction
is attempting to resolve, within the CoreDataCloudKitDemo WWDC 2019 “Utilizing Core Information with CloudKit”
I wish to see, what downside will happen, if processPersistentHistory
is just not executed.
By making the processPersistentHistory
empty, I attempt to do the next testing.
controllerDidChangeContent
is being known as. My guess is that, as a result of the backed SQLite is seamlessly up to date by CloudKit background activity, NSFetchedResultController
will probably be notified the SQLite DB change, and subsequently replace the UI. Examine the “Obtain CloudKit Modifications into Core Information” of https://developer.apple.com/documentation/coredata/mirroring_a_core_data_store_with_cloudkit/syncing_a_core_data_store_with_cloudkitcontrollerDidChangeContent
is being triggered accurately, I can observe the UI change carry out by NSFetchResultController
with out concern.Therefore, I’m not clear, on what downside processPersistentHistory
is attempting to resolve within the demo code. Might I do know what sort of check case I can carry out, to know the issue solved by processPersistentHistory
?
Primarily based on “Combine Retailer Modifications Related to the Present View”
Your app receives distant change notifications when the native retailer
updates from CloudKit. Nevertheless, it’s pointless to replace your UI in
response to each notification, as a result of some adjustments is probably not
related to the present view.Analyze the persistent historical past to find out whether or not the adjustments are
related to the present view earlier than consuming them within the consumer
interface. Examine the small print of every transaction, such because the entity
identify, its up to date properties, and the kind of change, to resolve
whether or not to behave.For extra details about persistent historical past monitoring, see Consuming
Related Retailer Modifications.
This half is getting complicated. Our NSFetchedResultController
is receiving related entity change occasion on account of SQLite, and subsequently capable of replace the UI appropriate. If this is so, why can we nonetheless want persistent historical past?
[ad_2]