Yes, the deletion rules are part of Core Data, not RestKit so they will be run.
When a orphaned object is deleted, are deletion rules applied?
-
16-07-2023 - |
Question
Let's say I have a class called Directory
and another called File
, and they have a one-to-many relationship. (A Directory
has many File
s).
In the restkit docs for RKManagedObjectRequestOperation
:
An NSOperation subclass that sends an HTTP request and performs object mapping on the parsed response body to createNSManagedObject instances, establishes relationships between objects using RKConnectionDescription objects, and cleans up orphaned objects that no longer exist in the remote backend system.
My question is if the deletion rules are applied by RestKit when an orphan object is found and deleted. In this case, would be all File
s get deleted? (If I use Cascade in deletion rule)
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow