-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Database.isOpen() #700
Comments
@cherrydev The built-in |
There are two SQLiteDatabase classes in two different packages, one for the standard, one for the encrypted. There is no common interface or subclass for these two SQLiteDatabase classes. Therefore a single call to isOpen() requires code for two |
Sorry, I missed the different package for |
Thanks! |
|
It would be great if the Database interface exposed the
.isOpen()
method of the delegate. I'm dealing with an app that uses AccountManager and has separate databases for each user. When an account is deleted, a callback deletes the underlying database, but if the app is still running, when my Activity resumes it needs to check if the database is still open. I can do it by getting the raw database and then casting it (to one of two implementation classes, depending on if it's encrypted or not) but it seems like adding.isOpen()
to the interface should be straightforward.I'd be happy to submit a pull request for it if the idea is approved. Thanks.
The text was updated successfully, but these errors were encountered: