Reputation: 3655
I can use for example ZipResourceFile library http://developer.android.com/google/play/expansion-files.html#ZipLib to get InputStream of file with database, but it has constructor
SQLiteDatabase openDatabase(String path, CursorFactory factory, int flags);
and need path to file.
Is it possible to open SQLiteDatabase readonly from ZIP file without unpacking in android?
Upvotes: 1
Views: 330
Reputation: 82563
You will have to unpack the database in any case, whether it is to memory or to the disk. So it really doesn't make much sense to not unpack it to the disk, as that will make your life easier when using such classes.
Upvotes: 2