From ff88f7bbe07fb3e267af49427adf1a91e3fc21e9 Mon Sep 17 00:00:00 2001 From: zachh Date: Tue, 9 Jan 2018 17:29:06 -0800 Subject: Added RealtimeRowProcessor. This is for performing work inside of the call log's RecyclerView, when the view holder is bound. Most of the time, this should be a no-op but there are possible edge cases where the call log data cannot be updated efficiently through the standard batch mechanism. One example of this is when there are too many invalid numbers in the call log; the CP2 information for invalid numbers cannot be efficiently batch updated so we fetch this information at display time. (Note that we do handle up to 5 invalid numbers in the batch update mechanism, but if there are more than that we fallback to this realtime processing.) Test: unit, manual PiperOrigin-RevId: 181400016 Change-Id: Iea6b380742e757b48d19f319fe46dc5fae837604 --- java/com/android/dialer/calllog/model/CoalescedRow.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'java/com/android/dialer/calllog/model/CoalescedRow.java') diff --git a/java/com/android/dialer/calllog/model/CoalescedRow.java b/java/com/android/dialer/calllog/model/CoalescedRow.java index 1824ba146..2520d996a 100644 --- a/java/com/android/dialer/calllog/model/CoalescedRow.java +++ b/java/com/android/dialer/calllog/model/CoalescedRow.java @@ -40,9 +40,12 @@ public abstract class CoalescedRow { .setIsVoicemail(false) .setCallType(0) .setCanReportAsInvalidNumber(false) + .setCp2InfoIncomplete(false) .setCoalescedIds(CoalescedIds.getDefaultInstance()); } + public abstract Builder toBuilder(); + public abstract int id(); public abstract long timestamp(); @@ -95,6 +98,8 @@ public abstract class CoalescedRow { public abstract boolean canReportAsInvalidNumber(); + public abstract boolean cp2InfoIncomplete(); + public abstract CoalescedIds coalescedIds(); /** Builder for {@link CoalescedRow}. */ @@ -144,6 +149,8 @@ public abstract class CoalescedRow { public abstract Builder setCanReportAsInvalidNumber(boolean canReportAsInvalidNumber); + public abstract Builder setCp2InfoIncomplete(boolean cp2InfoIncomplete); + public abstract Builder setCoalescedIds(CoalescedIds coalescedIds); public abstract CoalescedRow build(); -- cgit v1.2.3