Home
last modified time | relevance | path

Searched refs:compareTo (Results 1 – 25 of 151) sorted by relevance

1234567

/frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/inputmethod/
DComparableUtils.java44 final ToIntBiFunction<T, T> compareTo, final Function<T, String> name) { in assertAscendingOrdering() argument
49 compareTo.applyAsInt(x, y) < 0); in assertAscendingOrdering()
62 final ToIntBiFunction<T, T> compareTo, final Function<T, String> name) {
66 compareTo.applyAsInt(x, y) == 0);
87 final ToIntBiFunction<T, T> compareTo, final Function<T, String> name) {
91 compareTo.applyAsInt(x, x) == 0);
95 Integer.signum(compareTo.applyAsInt(x, y)),
96 -Integer.signum(compareTo.applyAsInt(y, x)));
99 if (compareTo.applyAsInt(x, y) > 0 && compareTo.applyAsInt(y, z) > 0) {
103 compareTo.applyAsInt(x, z) > 0);
[all …]
DInputMethodPreferenceTest.java57 (x, y) -> x.compareTo(y, COLLATOR), in testComparableOrdering()
69 (x, y) -> x.compareTo(y, COLLATOR), in testComparableEquality()
78 (x, y) -> x.compareTo(y, COLLATOR), in testComparableEquality()
102 (x, y) -> x.compareTo(y, COLLATOR), in testComparableContracts()
DInputMethodSubtypePreferenceTest.java68 (x, y) -> x.compareTo(y, COLLATOR), in testComparableOrdering()
76 (x, y) -> x.compareTo(y, COLLATOR), in testComparableEquality()
94 (x, y) -> x.compareTo(y, COLLATOR), in testComparableContracts()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/uicc/euicc/
DEuiccSpecVersionTest.java50 assertEquals(0, ver1.compareTo(ver2)); in testCompareTo()
51 assertEquals(0, ver2.compareTo(ver1)); in testCompareTo()
58 assertEquals(-1, ver1.compareTo(ver2)); in testCompareTo()
59 assertEquals(1, ver2.compareTo(ver1)); in testCompareTo()
64 assertEquals(-1, ver1.compareTo(ver2)); in testCompareTo()
65 assertEquals(1, ver2.compareTo(ver1)); in testCompareTo()
70 assertEquals(-1, ver1.compareTo(ver2)); in testCompareTo()
71 assertEquals(1, ver2.compareTo(ver1)); in testCompareTo()
76 assertEquals(-1, ver1.compareTo(ver2)); in testCompareTo()
77 assertEquals(1, ver2.compareTo(ver1)); in testCompareTo()
[all …]
/frameworks/base/core/java/android/util/
DRange.java58 if (lower.compareTo(upper) > 0) { in Range()
114 boolean gteLower = value.compareTo(mLower) >= 0; in contains()
115 boolean lteUpper = value.compareTo(mUpper) <= 0; in contains()
134 boolean gteLower = range.mLower.compareTo(mLower) >= 0; in contains()
135 boolean lteUpper = range.mUpper.compareTo(mUpper) <= 0; in contains()
176 if (value.compareTo(mLower) < 0) { in clamp()
178 } else if (value.compareTo(mUpper) > 0) { in clamp()
207 int cmpLower = range.mLower.compareTo(mLower); in intersect()
208 int cmpUpper = range.mUpper.compareTo(mUpper); in intersect()
240 int cmpLower = lower.compareTo(mLower); in intersect()
[all …]
/frameworks/base/services/tests/wmtests/src/com/android/server/wm/
DWindowConfigurationTests.java116 assertEquals(0, config1.compareTo(config2)); in testConfigurationCompareTo()
117 assertEquals(0, winConfig1.compareTo(winConfig2)); in testConfigurationCompareTo()
121 assertNotEquals(0, config1.compareTo(config2)); in testConfigurationCompareTo()
122 assertNotEquals(0, winConfig1.compareTo(winConfig2)); in testConfigurationCompareTo()
127 assertNotEquals(0, config1.compareTo(config2)); in testConfigurationCompareTo()
128 assertNotEquals(0, winConfig1.compareTo(winConfig2)); in testConfigurationCompareTo()
133 assertNotEquals(0, config1.compareTo(config2)); in testConfigurationCompareTo()
134 assertNotEquals(0, winConfig1.compareTo(winConfig2)); in testConfigurationCompareTo()
138 assertEquals(-1, config1.compareTo(blankConfig)); in testConfigurationCompareTo()
139 assertEquals(-1, winConfig1.compareTo(blankWinConfig)); in testConfigurationCompareTo()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DHalVersion.java41 public int compareTo(HalVersion ver) { in compareTo() method in HalVersion
64 return ((o instanceof HalVersion) && (o == this || compareTo((HalVersion) o) == 0)); in equals()
71 return compareTo(ver) > 0; in greater()
78 return compareTo(ver) < 0; in less()
DHardwareConfig.java199 public int compareTo(HardwareConfig hw) { in compareTo() method in HardwareConfig
203 return (one.compareTo(two)); in compareTo()
/frameworks/base/sax/java/android/sax/
DChildren.java45 && current.uri.compareTo(uri) == 0 in getOrCreate()
46 && current.localName.compareTo(localName) == 0) { in getOrCreate()
75 && current.uri.compareTo(uri) == 0 in get()
76 && current.localName.compareTo(localName) == 0) { in get()
DRootElement.java143 if (root.uri.compareTo(uri) != 0 in startRoot()
144 || root.localName.compareTo(localName) != 0) { in startRoot()
/frameworks/base/telephony/java/android/telephony/emergency/
DEmergencyNumber.java554 public int compareTo(@NonNull EmergencyNumber emergencyNumber) { in compareTo() method in EmergencyNumber
561 } else if (this.getNumber().compareTo(emergencyNumber.getNumber()) != 0) { in compareTo()
562 return this.getNumber().compareTo(emergencyNumber.getNumber()); in compareTo()
563 } else if (this.getCountryIso().compareTo(emergencyNumber.getCountryIso()) != 0) { in compareTo()
564 return this.getCountryIso().compareTo(emergencyNumber.getCountryIso()); in compareTo()
565 } else if (this.getMnc().compareTo(emergencyNumber.getMnc()) != 0) { in compareTo()
566 return this.getMnc().compareTo(emergencyNumber.getMnc()); in compareTo()
571 } else if (this.getEmergencyUrns().toString().compareTo( in compareTo()
573 return this.getEmergencyUrns().toString().compareTo( in compareTo()
/frameworks/base/core/java/com/android/internal/graphics/palette/
DVariationalKMeansQuantizer.java97 KMeans.Mean compareTo = optimalMeans.get(j); in quantize() local
98 float[] compareToCentroid = compareTo.getCentroid(); in quantize()
102 optimalMeans.remove(compareTo); in quantize()
103 current.getItems().addAll(compareTo.getItems()); in quantize()
/frameworks/base/services/robotests/backup/src/com/android/server/backup/encryption/chunk/
DChunkHashTest.java76 int result = chunkHash.compareTo(equalChunkHash); in testCompareTo_whenEqual_returnsZero()
86 int result = chunkHash1.compareTo(chunkHash2); in testCompareTo_whenArgumentGreater_returnsNegative()
96 int result = chunkHash2.compareTo(chunkHash1); in testCompareTo_whenArgumentSmaller_returnsPositive()
/frameworks/base/media/java/android/media/
DUtils.java50 if (lhs.getUpper().compareTo(rhs.getLower()) < 0) { in sortDistinctRanges()
52 } else if (lhs.getLower().compareTo(rhs.getUpper()) > 0) { in sortDistinctRanges()
73 one[ix].getUpper().compareTo(range.getLower()) < 0) { in intersectSortedDistinctRanges()
77 one[ix].getUpper().compareTo(range.getUpper()) < 0) { in intersectSortedDistinctRanges()
84 if (one[ix].getLower().compareTo(range.getUpper()) <= 0) { in intersectSortedDistinctRanges()
105 if (lhs.getUpper().compareTo(rhs.getLower()) < 0) { in binarySearchDistinctRanges()
107 } else if (lhs.getLower().compareTo(rhs.getUpper()) > 0) { in binarySearchDistinctRanges()
/frameworks/base/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/helpers/
DCameraErrorCollector.java239 msg, expected, actual), actual.compareTo(expected) > 0); in expectGreater()
253 msg, expected, actual), actual.compareTo(expected) >= 0); in expectGreaterOrEqual()
267 msg, expected, actual), actual.compareTo(expected) < 0); in expectLess()
281 msg, expected, actual), actual.compareTo(expected) <= 0); in expectLessOrEqual()
342 min.toString()), value.compareTo(min) >= 0); in expectValuesGreaterOrEqual()
372 value.compareTo(max)<= 0 && value.compareTo(min) >= 0); in expectValuesInRange()
420 value.compareTo(max)<= 0 && value.compareTo(min) >= 0); in expectInRange()
618 int compareResult = array[i + 1].compareTo(array[i]); in checkArrayMonotonicityAndNotAllEqual()
629 array[0].compareTo(array[array.length - 1]) != 0); in checkArrayMonotonicityAndNotAllEqual()
/frameworks/base/tools/preload/
DLoadedClass.java122 public int compareTo(LoadedClass o) { in compareTo() method in LoadedClass
123 return name.compareTo(o.name); in compareTo()
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/inputmethod/
DInputMethodSubtypePreference.java70 public int compareTo(final Preference rhs, final Collator collator) { in compareTo() method in InputMethodSubtypePreference
98 return super.compareTo(rhs); in compareTo()
/frameworks/base/services/tests/servicestests/src/com/android/server/inputmethod/
DInputMethodSubtypeSwitchingControllerTest.java437 assertTrue(item1 + " has the same order of itself", item1.compareTo(item1) == 0); in testImeSubtypeListComparator()
442 assertTrue(item1 + " is less than " + item2, item1.compareTo(item2) < 0); in testImeSubtypeListComparator()
443 assertTrue(item2 + " is greater than " + item1, item2.compareTo(item1) > 0); in testImeSubtypeListComparator()
454 assertTrue(nonSystemLocale1.compareTo(nonSystemLocale2) == 0); in testImeSubtypeListComparator()
455 assertTrue(nonSystemLocale2.compareTo(nonSystemLocale1) == 0); in testImeSubtypeListComparator()
465 assertTrue(ime1.compareTo(ime2) < 0); in testImeSubtypeListComparator()
466 assertTrue(ime2.compareTo(ime1) > 0); in testImeSubtypeListComparator()
/frameworks/base/core/java/android/service/notification/
DNotifyingApp.java120 public int compareTo(NotifyingApp o) { in compareTo() method in NotifyingApp
123 return getPackage().compareTo(o.getPackage()); in compareTo()
/frameworks/opt/timezonepicker/src/com/android/timezonepicker/
DTimeZoneInfo.java252 public int compareTo(TimeZoneInfo other) { in compareTo() method in TimeZoneInfo
267 int diff = this.mCountry.compareTo(other.mCountry); in compareTo()
276 return this.mDisplayName.compareTo(other.mDisplayName); in compareTo()
278 return this.mTz.getDisplayName(Locale.getDefault()).compareTo( in compareTo()
/frameworks/base/core/java/com/android/internal/ml/clustering/
DKMeans.java103 Mean compareTo = means.get(j); in score() local
104 if (mean == compareTo) { in score()
107 double distance = Math.sqrt(sqDistance(mean.mCentroid, compareTo.mCentroid)); in score()
/frameworks/base/test-runner/src/android/test/suitebuilder/
DTestGrouping.java166 int result = class1.getSimpleName().compareTo(class2.getSimpleName()); in compare()
170 return class1.getName().compareTo(class2.getName()); in compare()
183 return class1.getName().compareTo(class2.getName()); in compare()
/frameworks/base/tests/Internal/src/android/app/
DWallpaperInfoTest.java86 0, expectedUri.compareTo(settingsUri)); in testGetSettingsSliceUri()
92 0, expectedUri.compareTo(fromParcel.getSettingsSliceUri())); in testGetSettingsSliceUri()
/frameworks/base/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/unit/
DRationalTest.java441 left.compareTo(right) < 0); in assertLessThan()
443 right.compareTo(left) > 0); in assertLessThan()
448 left.compareTo(right) > 0); in assertGreaterThan()
450 right.compareTo(left) < 0); in assertGreaterThan()
455 left.compareTo(right) == 0); in assertCompareEquals()
457 right.compareTo(left) == 0); in assertCompareEquals()
/frameworks/base/packages/PrintSpooler/src/com/android/printspooler/util/
DMediaSizeUtils.java158 return Integer.valueOf(lhsStandard).compareTo(rhsStandard); in compare()
161 return getLabel(mContext, lhs).compareTo(getLabel(mContext, rhs)); in compare()

1234567