- Sort Score
- Num 10 results
- Language All
Results 1 - 7 of 7 for saturatedSubtract (0.08 seconds)
-
android/guava/src/com/google/common/cache/CacheStats.java
return new CacheStats( max(0, saturatedSubtract(hitCount, other.hitCount)), max(0, saturatedSubtract(missCount, other.missCount)), max(0, saturatedSubtract(loadSuccessCount, other.loadSuccessCount)), max(0, saturatedSubtract(loadExceptionCount, other.loadExceptionCount)), max(0, saturatedSubtract(totalLoadTime, other.totalLoadTime)), max(0, saturatedSubtract(evictionCount, other.evictionCount))); }
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Tue Jul 08 18:32:10 GMT 2025 - 12.6K bytes - Click Count (0) -
guava/src/com/google/common/cache/CacheStats.java
return new CacheStats( max(0, saturatedSubtract(hitCount, other.hitCount)), max(0, saturatedSubtract(missCount, other.missCount)), max(0, saturatedSubtract(loadSuccessCount, other.loadSuccessCount)), max(0, saturatedSubtract(loadExceptionCount, other.loadExceptionCount)), max(0, saturatedSubtract(totalLoadTime, other.totalLoadTime)), max(0, saturatedSubtract(evictionCount, other.evictionCount))); }
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Tue Jul 08 18:32:10 GMT 2025 - 12.6K bytes - Click Count (0) -
android/guava/src/com/google/common/math/IntMath.java
* which case {@code Integer.MAX_VALUE} or {@code Integer.MIN_VALUE} is returned, respectively. * * @since 20.0 */ public static int saturatedSubtract(int a, int b) { return Ints.saturatedCast((long) a - b); } /** * Returns the product of {@code a} and {@code b} unless it would overflow or underflow in whichCreated: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Jan 29 22:14:05 GMT 2026 - 26.1K bytes - Click Count (0) -
android/guava/src/com/google/common/math/LongMath.java
* * @since 20.0 */ // Whenever both tests are cheap and functional, it's faster to use &, | instead of &&, || @SuppressWarnings("ShortCircuitBoolean") public static long saturatedSubtract(long a, long b) { long naiveDifference = a - b; if ((a ^ b) >= 0 | (a ^ naiveDifference) >= 0) { // If a and b have the same signs or a has the same sign as the result then there was no
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 09 23:01:02 GMT 2026 - 46.8K bytes - Click Count (0) -
guava-tests/test/com/google/common/math/IntMathTest.java
for (int b : ALL_INTEGER_CANDIDATES) { assertOperationEquals( a, b, "s-", saturatedCast(valueOf(a).subtract(valueOf(b))), IntMath.saturatedSubtract(a, b)); } } } @AndroidIncompatible // slow @GwtIncompatible // TODO public void testSaturatedMultiply() { for (int a : ALL_INTEGER_CANDIDATES) {
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Aug 11 19:31:30 GMT 2025 - 24.1K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/math/IntMathTest.java
for (int b : ALL_INTEGER_CANDIDATES) { assertOperationEquals( a, b, "s-", saturatedCast(valueOf(a).subtract(valueOf(b))), IntMath.saturatedSubtract(a, b)); } } } @AndroidIncompatible // slow @GwtIncompatible // TODO public void testSaturatedMultiply() { for (int a : ALL_INTEGER_CANDIDATES) {
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Aug 11 19:31:30 GMT 2025 - 24.1K bytes - Click Count (0) -
guava-tests/test/com/google/common/math/LongMathTest.java
for (long b : ALL_LONG_CANDIDATES) { assertOperationEquals( a, b, "s-", saturatedCast(valueOf(a).subtract(valueOf(b))), LongMath.saturatedSubtract(a, b)); } } } @AndroidIncompatible // slow @GwtIncompatible // TODO public void testSaturatedMultiply() { for (long a : ALL_LONG_CANDIDATES) {
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Oct 30 14:15:36 GMT 2025 - 31.4K bytes - Click Count (0)