summaryrefslogtreecommitdiff
path: root/src/com/android/dialer/service
diff options
context:
space:
mode:
authorYorke Lee <yorkelee@google.com>2013-08-26 15:46:10 -0700
committerYorke Lee <yorkelee@google.com>2013-08-28 10:02:45 -0700
commit034a2b329e469bf6888fbbcf91992f974015c2a8 (patch)
tree98b175320a6b1e3ce21aaae21a0e37def986407d /src/com/android/dialer/service
parent0baa98b5163f83a715b37e3cffe1488ac88ab049 (diff)
Use contacts cache in call log adapter
Bug: 10490038 Change-Id: I4c7fc5094f76dfaaa321bc69d595f37bb72f87ad
Diffstat (limited to 'src/com/android/dialer/service')
-rw-r--r--src/com/android/dialer/service/CachedNumberLookupService.java19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/com/android/dialer/service/CachedNumberLookupService.java b/src/com/android/dialer/service/CachedNumberLookupService.java
new file mode 100644
index 000000000..a08c28564
--- /dev/null
+++ b/src/com/android/dialer/service/CachedNumberLookupService.java
@@ -0,0 +1,19 @@
+package com.android.dialer.service;
+
+import android.content.Context;
+
+import com.android.dialer.calllog.ContactInfo;
+
+public interface CachedNumberLookupService {
+ /**
+ * Perform a lookup using the cached number lookup service to return contact
+ * information stored in the cache that corresponds to the given number.
+ *
+ * @param context Valid context
+ * @param number Phone number to lookup the cache for
+ * @return A {@link ContactInfo} containing the contact information if the phone
+ * number is found in the cache, {@link ContactInfo#EMPTY} if the phone number was
+ * not found in the cache, and null if there was an error when querying the cache.
+ */
+ public ContactInfo lookupCachedContactFromNumber(Context context, String number);
+}