Only if you had Kara Trace in your address book already. But if you add it after you start monitoring, you need to query the whole database to see if Kara has been added or not to your address book. And if she did, then you start monitoring of her. Imaging that you have 10 different girls with name Kara Trace in your address book. Then you have to subscribe to 10 different URIs, and still to keep monitoring if a new Kara Trace entry has been added to your address book. Further, my application/service would have to subscribe to all database changes, as someone may rename another contact and name her Kara Trace. Then, what if I want to add Sharon Valerii too? The system will be overloaded with my observers, and the amount of work is just... ridiculous.
On Jun 15, 8:04 pm, Marco Nelissen <[email protected]> wrote: > The notifications is for a specific URI, so you can choose to be notified > when *any* contact changes (by using a URI like > "content://contacts/people"), or specifically when the contact info for > Starbuck is changed (by using a URI like "content://contacts/people/1") > > > > On Mon, Jun 15, 2009 at 10:53 AM, MannyNS <[email protected]> wrote: > > > Anyone? > > > On Jun 10, 5:38 pm, MannyNS <[email protected]> wrote: > > > Using ContentResolver and ContentObserver, it is possible to receive > > > notifications in the function onChange() when some data is changed > > > within the content provider. However, I fail to see if there is a way > > > to see the URI which triggered the notification. > > > > For instance, if I want to play a sound when someone deletes "Kara > > > Trace" from my address book or whatever - how do I do that, if not by > > > having another copy of the whole content provider dataset, and then > > > comparing the old dataset copy with a new one? > > > Can someone confirm me that the hard way is the only way? > > > > Thanks. > > > > P. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

