I am using RestKit for webservice calls, caching, and etags. I implemented my own coredata model and managedObjects
As soon as the user signs out I need to clear all data in the database. I was able to successfully delete the sqlite file and recreate it, but I can't find out a way to clear all RestKit catching and etag data. How can I completely wipe all data stored by RestKit?
You want to call [[RKClient sharedClient].requestCache invalidateAll];
to wipe the cache clean. You can view the API docs.
Use the following method from the RKManagedObjectStore class.
- (void)deletePersistantStoreUsingSeedDatabaseName:(NSString *)seedFile
http://restkit.org/api/0.9/Classes/RKManagedObjectStore.html#//api/name/deletePersistantStoreUsingSeedDatabaseName:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With