How enable iCloud support for sqlite?

后端 未结 2 1258
醉梦人生
醉梦人生 2020-12-15 11:59

I want to provide iCloud support for my wrapper around sqlite. Is not using coredata.

I wonder how enable iCloud for it. The database content is changed all the time

2条回答
  •  执笔经年
    2020-12-15 12:47

    The short answer is no, you would need to use Core Data as you suspected. Apple has stated that sqlite is unsupported.

    Edit: Check out the section on iCloud that's now in the iOS Application Programming Guide under Using iCloud in Conjunction with Databases

    Using iCloud with a SQLite database is possible only if your app uses Core Data to manage that database. Accessing live database files in iCloud using the SQLite interfaces is not supported and will likely corrupt your database. However, you can create a Core Data store based on SQLite as long as you follow a few extra steps when setting up your Core Data structures. You can also continue to use other types of Core Data stores—that is, stores not based on SQLite—without any special modifications.

提交回复
热议问题