Clearing CoreData and all that inside

后端 未结 4 813
日久生厌
日久生厌 2021-02-08 09:32

I\'m pretty new to CoreData and this app that uses it. And I\'m currently working on a feature that clears the entire core data when I log out in the app.

I have 2 sqlli

4条回答
  •  佛祖请我去吃肉
    2021-02-08 10:02

    If your app can create the files then just remove them when the app quits. If you have some notion of a database that has valuable schema info, and you just need to truncate the file, that isn't really the case in core data... The schema is in the compiled entity models and xcwhatever files.

    Also I must have just read it wrong, because if you want core data to be not persistent then you are using the wrong tool.

提交回复
热议问题