Cancel query result that is no longer valid.
When sign in with an account and connect phone, the contact database will
aggragate the contacts and notify the InMemoryPhoneBook to reload a few
times in a very short time. This change will cancel any pending query
tasks and any pending result handling tasks when a new query starts. It
also increase the token to verify if a query result is out of date and
should be ignored.
Bug: 122311541
Test: manual testing
Change-Id: I4e5534cb5ed1f5e1483f20e9baf3be9ed0b30bcd
1 file changed