diff options
Diffstat (limited to 'src/com/android/dialer/service')
-rw-r--r-- | src/com/android/dialer/service/CachedNumberLookupService.java | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/src/com/android/dialer/service/CachedNumberLookupService.java b/src/com/android/dialer/service/CachedNumberLookupService.java index cba158b53..62881d2fe 100644 --- a/src/com/android/dialer/service/CachedNumberLookupService.java +++ b/src/com/android/dialer/service/CachedNumberLookupService.java @@ -7,29 +7,27 @@ import com.android.dialer.calllog.ContactInfo; public interface CachedNumberLookupService { - public class CachedContactInfo extends ContactInfo { - public static final int SOURCE_TYPE_DIRECTORY = 1; - public static final int SOURCE_TYPE_EXTENDED = 2; - public static final int SOURCE_TYPE_PLACES = 3; - public static final int SOURCE_TYPE_PROFILE = 4; - - public String sourceName; - public int sourceType; - public int sourceId; - public String lookupKey; + public interface CachedContactInfo { + public ContactInfo getContactInfo(); + + public void setDirectorySource(String name, long directoryId); + public void setExtendedSource(String name, long directoryId); + public void setLookupKey(String lookupKey); } + public CachedContactInfo buildCachedContactInfo(ContactInfo info); + /** * 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 + * @return A {@link CachedContactInfo} 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); + public CachedContactInfo lookupCachedContactFromNumber(Context context, String number); public void addContact(Context context, CachedContactInfo info); |