Add property invalidated cache to TelephonyManager.
Adding cache for the getSubscriptionId(PHoneAccountHandle) method.
We invalidate the cache in Telephony whenever phone account handles are
torn down to ensure that nobody has old cached data kicking around.
Test: Added unit test which confirms the number of AIDL calls when the
cache is operating as expected.
Test: Manual test; verified that I can see the property invalidated cache
logs which indicate that there are cache hits going on.
Bug: 224654574
Change-Id: I11c7c3b6ffa4111fbee5f451151e7f8f245908d1
3 files changed