/packages/modules/StatsD/statsd/tests/e2e/ |
D | PartialBucket_e2e_test.cpp | 122 int64_t start = getElapsedRealtimeNs(); // This is the start-time the metrics producers are in TEST() local 125 service->mProcessor->OnLogEvent(CreateAppCrashEvent(start + 1, 100).get()); in TEST() 126 service->mProcessor->OnLogEvent(CreateAppCrashEvent(start + 2, 100).get()); in TEST() 128 ConfigMetricsReport report = GetReports(service->mProcessor, start + 3); in TEST() 137 int64_t start = getElapsedRealtimeNs(); // This is the start-time the metrics producers are in TEST() local 141 service->mProcessor->OnLogEvent(CreateAppCrashEvent(start + 1, 100).get()); in TEST() 144 service->mUidMap->updateApp(start + 2, String16(kApp1.c_str()), 1, 2, String16("v2"), in TEST() 147 service->mProcessor->OnLogEvent(CreateAppCrashEvent(start + 3, 100).get()); in TEST() 149 ConfigMetricsReport report = GetReports(service->mProcessor, start + 4); in TEST() 157 int64_t start = getElapsedRealtimeNs(); // This is the start-time the metrics producers are in TEST() local [all …]
|
/packages/apps/Contacts/src/com/android/contacts/widget/ |
D | CompositeListAdapter.java | 141 int start = 0; in getItem() local 143 int end = start + mCounts[i]; in getItem() 144 if (position >= start && position < end) { in getItem() 145 return mAdapters[i].getItem(position - start); in getItem() 147 start = end; in getItem() 155 int start = 0; in getItemId() local 157 int end = start + mCounts[i]; in getItemId() 158 if (position >= start && position < end) { in getItemId() 159 return mAdapters[i].getItemId(position - start); in getItemId() 161 start = end; in getItemId() [all …]
|
/packages/apps/Messaging/src/com/android/messaging/ui/ |
D | CompositeAdapter.java | 145 int start = 0; in getPartitionAtPosition() local 147 final int end = start + mPartitions[i].getCount(); in getPartitionAtPosition() 148 if (position >= start && position < end) { in getPartitionAtPosition() 149 int offset = position - start; in getPartitionAtPosition() 159 start = end; in getPartitionAtPosition() 196 int start = 0; in getItem() local 198 final int end = start + mPartitions[i].getCount(); in getItem() 199 if (position >= start && position < end) { in getItem() 200 final int offset = position - start; in getItem() 209 start = end; in getItem() [all …]
|
/packages/apps/Calendar/tests/src/com/android/calendar/ |
D | UtilsTests.java | 229 long start = createTimeInMillis(0, 0, 17, 12, 3, 2000); in testGetDisplayedDatetime_differentYear() local 231 String result = Utils.getDisplayedDatetime(start, end, NOW_TIME, DEFAULT_TIMEZONE, in testGetDisplayedDatetime_differentYear() 236 start = createTimeInMillis(0, 0, 17, 31, 11, 2012); in testGetDisplayedDatetime_differentYear() 238 result = Utils.getDisplayedDatetime(start, end, NOW_TIME, DEFAULT_TIMEZONE, in testGetDisplayedDatetime_differentYear() 246 long start = createTimeInMillis(0, 0, 17, 12, 3, 2012); in testGetDisplayedDatetime_sameYear() local 248 String result = Utils.getDisplayedDatetime(start, end, NOW_TIME, DEFAULT_TIMEZONE, in testGetDisplayedDatetime_sameYear() 256 long start = createTimeInMillis(0, 0, 17, NOW_DAY, NOW_MONTH, NOW_YEAR); in testGetDisplayedDatetime_today() local 258 String result = Utils.getDisplayedDatetime(start, end, NOW_TIME, DEFAULT_TIMEZONE, in testGetDisplayedDatetime_today() 266 long start = createTimeInMillis(0, 0, 17, NOW_DAY, NOW_MONTH, NOW_YEAR); in testGetDisplayedDatetime_todayMidnight() local 268 String result = Utils.getDisplayedDatetime(start, end, NOW_TIME, DEFAULT_TIMEZONE, in testGetDisplayedDatetime_todayMidnight() [all …]
|
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/ |
D | OverScroller.java | 667 private void adjustDuration(int start, int oldFinal, int newFinal) { in adjustDuration() argument 668 final int oldDistance = oldFinal - start; in adjustDuration() 669 final int newDistance = newFinal - start; in adjustDuration() 682 void startScroll(int start, int distance, int duration) { in startScroll() argument 685 mStart = start; in startScroll() 686 mFinal = start + distance; in startScroll() 716 boolean springback(int start, int min, int max) { in springback() argument 719 mStart = mFinal = start; in springback() 725 if (start < min) { in springback() 726 startSpringback(start, min, 0); in springback() [all …]
|
/packages/modules/StatsD/statsd/src/matchers/ |
D | matcher_util.cpp | 101 const vector<FieldValue>& values, int start, int end, int depth) { in matchesSimple() argument 107 if (start >= end) { in matchesSimple() 116 for (int i = start; i < end; i++) { in matchesSimple() 129 start = newStart; in matchesSimple() 132 if (start == -1) { in matchesSimple() 146 for (int i = start; i < end; i++) { in matchesSimple() 155 ranges.push_back(std::make_pair(start, end)); in matchesSimple() 160 for (int i = start; i < end; i++) { in matchesSimple() 162 start = i; in matchesSimple() 166 ranges.push_back(std::make_pair(start, end)); in matchesSimple() [all …]
|
/packages/modules/Connectivity/framework/src/android/net/ |
D | UidRange.java | 35 public final int start; field in UidRange 42 start = startUid; in UidRange() 49 final int start = user.getUid(0 /* appId */); in createForUser() local 51 return new UidRange(start, end); in createForUser() 56 return UserHandle.getUserHandleForUid(start).getIdentifier(); in getStartUser() 66 return start <= uid && uid <= stop; in contains() 73 return 1 + stop - start; in count() 80 return start <= other.start && other.stop <= stop; in containsRange() 86 result = 31 * result + start; in hashCode() 98 return start == other.start && stop == other.stop; in equals() [all …]
|
/packages/apps/Gallery2/src/com/android/gallery3d/data/ |
D | MediaSet.java | 72 public ArrayList<MediaItem> getMediaItem(int start, int count) { in getMediaItem() argument 122 int start = Math.max(0, in getIndexOfItem() local 125 start, MEDIAITEM_BATCH_FETCH_COUNT); in getIndexOfItem() 127 if (index != INDEX_NOT_FOUND) return start + index; in getIndexOfItem() 130 start = start == 0 ? MEDIAITEM_BATCH_FETCH_COUNT : 0; in getIndexOfItem() 131 list = getMediaItem(start, MEDIAITEM_BATCH_FETCH_COUNT); in getIndexOfItem() 134 if (index != INDEX_NOT_FOUND) return start + index; in getIndexOfItem() 136 start += MEDIAITEM_BATCH_FETCH_COUNT; in getIndexOfItem() 137 list = getMediaItem(start, MEDIAITEM_BATCH_FETCH_COUNT); in getIndexOfItem() 204 int start = 0; in enumerateMediaItems() local [all …]
|
/packages/modules/DnsResolver/ |
D | OperationLimiterTest.cpp | 27 EXPECT_TRUE(limiter.start(42)); in TEST() 28 EXPECT_TRUE(limiter.start(42)); in TEST() 29 EXPECT_TRUE(limiter.start(42)); in TEST() 32 EXPECT_FALSE(limiter.start(42)); in TEST() 33 EXPECT_FALSE(limiter.start(42)); in TEST() 34 EXPECT_FALSE(limiter.start(42)); in TEST() 38 EXPECT_TRUE(limiter.start(42)); in TEST() 41 EXPECT_FALSE(limiter.start(42)); in TEST() 44 EXPECT_TRUE(limiter.start(666)); in TEST() 60 EXPECT_TRUE(limiter.start(42)); in TEST() [all …]
|
/packages/providers/ContactsProvider/src/com/android/providers/contacts/ |
D | ContactLookupKey.java | 91 int start = 0; in appendEscapedSourceId() local 93 int index = sourceId.indexOf('.', start); in appendEscapedSourceId() 95 sb.append(sourceId, start, sourceId.length()); in appendEscapedSourceId() 100 sb.append(sourceId, start, index); in appendEscapedSourceId() 102 start = index + 1; in appendEscapedSourceId() 187 int start = offset; in parse() local 195 key = string.substring(start); in parse() 197 key = string.substring(start, offset - 1); in parse() 203 int start = offset; in parse() local 211 key = string.substring(start); in parse() [all …]
|
/packages/apps/Car/SystemUI/src/com/android/systemui/car/hvac/ |
D | TemperatureColorStore.java | 139 private float hueLerp(float fraction, float start, float end) { in hueLerp() argument 141 if (start == end) { in hueLerp() 142 return start; in hueLerp() 147 if (Math.abs(start - end) > 180f) { in hueLerp() 148 if (start < end) { in hueLerp() 149 start += 360f; in hueLerp() 155 return lerp(fraction, start, end) % 360f; in hueLerp() 159 private float lerp(float fraction, float start, float end) { in lerp() argument 161 if (start == end) { in lerp() 162 return start; in lerp() [all …]
|
/packages/apps/DocumentsUI/src/com/android/documentsui/sorting/ |
D | SortingCursorWrapper.java | 202 for (int start = 1; start < count; start++) { in binarySort() 203 final int pivotPosition = positions[start]; in binarySort() 204 final String pivotValue = sortKey[start]; in binarySort() 205 final boolean pivotIsDir = isDirs[start]; in binarySort() 206 final String pivotId = ids[start]; in binarySort() 209 int right = start; in binarySort() 249 int n = start - left; in binarySort() 283 for (int start = 1; start < count; start++) { in binarySort() 284 final int pivotPosition = positions[start]; in binarySort() 285 final long pivotValue = sortKey[start]; in binarySort() [all …]
|
/packages/apps/Dialer/java/com/android/contacts/common/util/ |
D | SearchUtil.java | 40 int start = index - 1; in findMatchingLine() local 41 while (start > -1) { in findMatchingLine() 42 if (contents.charAt(start) == '\n') { in findMatchingLine() 45 start--; in findMatchingLine() 54 matched.line = contents.substring(start + 1, end); in findMatchingLine() 55 matched.startIndex = index - (start + 1); in findMatchingLine() 157 int start = 0; in cleanStartAndEndOfSearchQuery() local 158 while (start < query.length()) { in cleanStartAndEndOfSearchQuery() 159 int codePoint = query.codePointAt(start); in cleanStartAndEndOfSearchQuery() 163 start += Character.charCount(codePoint); in cleanStartAndEndOfSearchQuery() [all …]
|
/packages/apps/Contacts/src/com/android/contacts/util/ |
D | SearchUtil.java | 57 int start = index - 1; in findMatchingLine() local 58 while (start > -1) { in findMatchingLine() 59 if (contents.charAt(start) == '\n') { in findMatchingLine() 62 start--; in findMatchingLine() 71 matched.line = contents.substring(start + 1, end); in findMatchingLine() 72 matched.startIndex = index - (start + 1); in findMatchingLine() 174 int start = 0; in cleanStartAndEndOfSearchQuery() local 175 while (start < query.length()) { in cleanStartAndEndOfSearchQuery() 176 int codePoint = query.codePointAt(start); in cleanStartAndEndOfSearchQuery() 180 start += Character.charCount(codePoint); in cleanStartAndEndOfSearchQuery() [all …]
|
/packages/providers/MediaProvider/src/com/android/providers/media/util/ |
D | RedactingFileDescriptor.java | 113 public static long[] removeRange(long[] ranges, long start, long end) { in removeRange() argument 114 if (start == end) { in removeRange() 116 } else if (start > end) { in removeRange() 122 if (start <= ranges[i] && end >= ranges[i + 1]) { in removeRange() 124 } else if (start >= ranges[i] && end <= ranges[i + 1]) { in removeRange() 128 res[res.length - 3] = start; in removeRange() 139 if (start >= ranges[i] && start <= ranges[i + 1]) { in removeRange() 140 res[res.length - 1] = Math.min(ranges[i + 1], start); in removeRange() 174 final long start = Math.max(offset, ranges[i]); 176 for (long j = start; j < end; j++) { [all …]
|
/packages/modules/Wifi/service/java/com/android/server/wifi/util/ |
D | IntHistogram.java | 53 public int start; field in IntHistogram.Bucket 57 public Bucket(int start, int end, int count) { in Bucket() argument 58 this.start = start; in Bucket() 121 int start = bucketKey == 0 in getBucketByIndex() local 126 return new Bucket(start, end, count); in getBucketByIndex() 179 double value = Math.max(hitBucket.start, minimum); in quantileFunction() 267 T convert(int start, int end, int count); in convert() argument 282 output[i] = converter.convert(bucket.start, bucket.end, bucket.count); in toProto() 292 return toProto(HistogramBucketInt32.class, (start, end, count) -> { in toProto() 294 hb.start = start; in toProto()
|
/packages/providers/MediaProvider/tests/client/src/com/android/providers/media/client/ |
D | PerformanceTest.java | 109 timers.actionInsert.start(); in doSingle() 113 timers.notifyInsert.start(); in doSingle() 125 timers.actionUpdate.start(); in doSingle() 129 timers.notifyUpdate.start(); in doSingle() 138 timers.actionDelete.start(); in doSingle() 142 timers.notifyDelete.start(); in doSingle() 182 timers.actionInsert.start(); in doBulk() 186 timers.notifyInsert.start(); in doBulk() 202 timers.actionUpdate.start(); in doBulk() 206 timers.notifyUpdate.start(); in doBulk() [all …]
|
/packages/apps/QuickSearchBox/src/com/android/quicksearchbox/ |
D | SuggestionFormatter.java | 42 protected void applyQueryTextStyle(Spannable text, int start, int end) { in applyQueryTextStyle() argument 43 if (start == end) return; in applyQueryTextStyle() 44 setSpans(text, start, end, mSpanFactory.createSuggestionQueryTextAppearance()); in applyQueryTextStyle() 47 protected void applySuggestedTextStyle(Spannable text, int start, int end) { in applySuggestedTextStyle() argument 48 if (start == end) return; in applySuggestedTextStyle() 49 setSpans(text, start, end, mSpanFactory.createSuggestionSuggestedTextAppearance()); in applySuggestedTextStyle() 52 private void setSpans(Spannable text, int start, int end, Object[] spans) { in setSpans() argument 54 text.setSpan(span, start, end, 0); in setSpans()
|
/packages/apps/Gallery2/src/com/android/gallery3d/app/ |
D | AlbumDataLoader.java | 112 mReloadTask.start(); in resume() 161 int start = mContentStart; in setContentWindow() local 170 if (contentStart >= end || start >= contentEnd) { in setContentWindow() 171 for (int i = start, n = end; i < n; ++i) { in setContentWindow() 175 for (int i = start; i < contentStart; ++i) { in setContentWindow() 185 public void setActiveWindow(int start, int end) { in setActiveWindow() argument 186 if (start == mActiveStart && end == mActiveEnd) return; in setActiveWindow() 188 Utils.assertTrue(start <= end in setActiveWindow() 189 && end - start <= mData.length && end <= mSize); in setActiveWindow() 192 mActiveStart = start; in setActiveWindow() [all …]
|
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/ |
D | WakeupControllerTest.java | 277 mWakeupController.start(); in startSetsWakeupLock() 288 mWakeupController.start(); in startDoesNotRecordIgnoredStart() 298 mWakeupController.start(); in startDoesNotSetWakeupLockWhenDisabled() 311 mWakeupController.start(); in startDoesNotSetWakeupLockWhenNoSavedNetworksOrSuggestions() 325 mWakeupController.start(); in startIsIgnoredIfAlreadyActive() 330 mWakeupController.start(); in startIsIgnoredIfAlreadyActive() 342 mWakeupController.start(); in startRegistersScanListener() 352 mWakeupController.start(); in stopDeresgistersScanListener() 369 mWakeupController.start(); in resetSetsActiveToFalse() 377 mWakeupController.start(); in resetSetsActiveToFalse() [all …]
|
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/utils/ |
D | RecapitalizeStatusTests.java | 39 status.start(30, 40, "abcdefghij", Locale.ENGLISH, SPACE); in testTrim() 45 status.start(30, 44, " abcdefghij", Locale.ENGLISH, SPACE); in testTrim() 51 status.start(30, 40, "abcdefgh ", Locale.ENGLISH, SPACE); in testTrim() 57 status.start(30, 45, " abcdefghij ", Locale.ENGLISH, SPACE); in testTrim() 67 status.start(29, 40, "abcd efghij", Locale.ENGLISH, SPACE); in testRotate() 79 status.start(29, 40, "Abcd Efghij", Locale.ENGLISH, SPACE); in testRotate() 91 status.start(29, 40, "ABCD EFGHIJ", Locale.ENGLISH, SPACE); in testRotate() 103 status.start(29, 39, "AbCDefghij", Locale.ENGLISH, SPACE); in testRotate() 117 status.start(29, 40, "Abcd efghij", Locale.ENGLISH, SPACE); in testRotate() 131 status.start(30, 34, "grüß", Locale.GERMAN, SPACE); in testRotate() [all …]
|
/packages/modules/StatsD/tests/src/android/cts/statsd/atom/ |
D | BufferDebug.java | 87 private static void writeRow(StringBuilder str, byte[] buf, int start, int len, int max) { in writeRow() argument 91 f.format("%10d 0x%08x ", start, start); in writeRow() 94 int end = start + len; in writeRow() 97 if (start + WIDTH > max) { in writeRow() 103 for (int i = start; i < end; i++) { in writeRow() 105 if (i == start + HALF_WIDTH - 1) { in writeRow() 117 for (int i = start; i < end; i++) { in writeRow() 124 if (i == start + HALF_WIDTH - 1) { in writeRow()
|
/packages/apps/Contacts/tests/src/com/android/contacts/format/ |
D | SpannedTestUtils.java | 56 public static void assertPrefixSpan(CharSequence seq, int start, int end) { in assertPrefixSpan() argument 60 if (start > 0) { in assertPrefixSpan() 61 Assert.assertEquals(0, getNumForegroundColorSpansBetween(spannable, 0, start - 1)); in assertPrefixSpan() 63 Assert.assertEquals(1, getNumForegroundColorSpansBetween(spannable, start, end)); in assertPrefixSpan() 68 private static int getNumForegroundColorSpansBetween(Spanned value, int start, int end) { in getNumForegroundColorSpansBetween() argument 69 return value.getSpans(start, end, StyleSpan.class).length; in getNumForegroundColorSpansBetween() 83 public static int getNextTransition(SpannableString seq, int start) { in getNextTransition() argument 84 return seq.nextSpanTransition(start, seq.length(), StyleSpan.class); in getNextTransition()
|
/packages/apps/Calendar/src/com/android/calendar/widget/ |
D | CalendarAppWidgetModel.java | 85 long start; field in CalendarAppWidgetModel.EventInfo 128 result = prime * result + (int) (start ^ (start >>> 32)); in hashCode() 155 if (start != other.start) in equals() 283 long start = cursor.getLong(CalendarAppWidgetService.INDEX_BEGIN); in buildFromCursor() local 298 start = Utils.convertAlldayUtcToLocal(recycle, start, tz); in buildFromCursor() 303 Log.d(TAG, "Row #" + rowId + " allDay:" + allDay + " start:" + start in buildFromCursor() 314 mEventInfos.add(populateEventInfo(eventId, allDay, start, end, startDay, endDay, title, in buildFromCursor() 354 private EventInfo populateEventInfo(long eventId, boolean allDay, long start, long end, in populateEventInfo() argument 365 whenString.append(Utils.formatDateRange(mContext, start, end, flags)); in populateEventInfo() 374 whenString.append(Utils.formatDateRange(mContext, start, end, flags)); in populateEventInfo() [all …]
|
/packages/providers/MediaProvider/tests/utils/src/com/android/providers/media/tests/utils/ |
D | Timer.java | 37 private long start; field in Timer 44 public void start() { in start() method in Timer 45 if (start != 0) { in start() 48 start = SystemClock.elapsedRealtimeNanos(); in start() 54 if (start == 0) { in stop() 57 currentRunDuration = (SystemClock.elapsedRealtimeNanos() - start); in stop() 61 start = 0; in stop()
|