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 Files).

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 Files get deleted? (If I use Cascade in deletion rule)

Was it helpful?

Solution

Yes, the deletion rules are part of Core Data, not RestKit so they will be run.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top