-
Notifications
You must be signed in to change notification settings - Fork 136
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
Without declaring NotifyInsert/Update/Delete, insert, update and delete operations still invoke onLoadFinished #59
Comments
or is it true that the delete insert and update operation on certain URI guarantees to notify that exact URI and cursor returned by the query of the same URI will be notified (and thus invoke onLoadFinished). I only need to declare @NotifyInsert, @NotifyBulkInsert, @NotifyUpdate and @NotifyDelete when other URIs are also affected? |
Yep, the |
Thanks!! Then can I say this part of the sample code is redundant? |
It's redundant, yes. Was probably added to test that it works :) |
Thanks!! One more question, is it true that adding the update/delete/insert annotations will notify those returned URIs in addition to the modified URI, right? It's not replacing. It's declaring some extra uri getting notified plus the Uri by default. |
It replaces, but nothing's stopping you from returning the same |
I just did. I guess it's this chunk of code did the replace job, right? I hope some helpful doc can be added because this @NotifyXxxxx annotations don't really explain themselves. |
Yes, that's the code that generates the |
Wow. I didn't know that!!!!! This is so helpful. btw, it's |
I guess it's a feature rather than a bug yet I feel it's quite odd.
I find that even without declaring
@NotifyInsert
,@NotifyBulkInsert
,@NotifyUpdate
and@NotifyDelete
, the onLoadFinished (of a cursorLoader with query of certain URI) callback function still get invoked when insert, update and delete operations is performed to that URI.I guess this is not a bug? It's just quite wired because supporting
@NotifyInsert
,@NotifyBulkInsert
,@NotifyUpdate
and@NotifyDelete
somehow means that no notifying on data change without declaring these annotations.I declare the URI with
and query the database by defining a cursorLoader
and modify the database with
Then onLoadFinished gets called automatically without I declaring notifyDelete
The text was updated successfully, but these errors were encountered: