- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 22 for checkedList (0.1 sec)
-
android/guava/src/com/google/common/primitives/SignedBytes.java
* @return the {@code byte} value that equals {@code value} * @throws IllegalArgumentException if {@code value} is greater than {@link Byte#MAX_VALUE} or * less than {@link Byte#MIN_VALUE} */ public static byte checkedCast(long value) { byte result = (byte) value; checkArgument(result == value, "Out of range: %s", value); return result; } /** * Returns the {@code byte} nearest in value to {@code value}. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 13:00:28 UTC 2024 - 7.3K bytes - Viewed (0) -
guava/src/com/google/common/hash/BloomFilterStrategies.java
// Avoid delegating to this(long[]), since AtomicLongArray(long[]) will clone its input and // thus double memory usage. this.data = new AtomicLongArray(Ints.checkedCast(LongMath.divide(bits, 64, RoundingMode.CEILING))); this.bitCount = LongAddables.create(); } // Used by serialization LockFreeBitArray(long[] data) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Oct 10 19:45:10 UTC 2022 - 10.7K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/primitives/IntsTest.java
for (int value : VALUES) { assertThat(Ints.hashCode(value)).isEqualTo(((Integer) value).hashCode()); } } public void testCheckedCast() { for (int value : VALUES) { assertThat(Ints.checkedCast((long) value)).isEqualTo(value); } assertCastFails(GREATEST + 1L); assertCastFails(LEAST - 1L); assertCastFails(Long.MAX_VALUE); assertCastFails(Long.MIN_VALUE); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 02:56:12 UTC 2024 - 29.1K bytes - Viewed (0) -
android/guava/src/com/google/common/hash/BloomFilter.java
// 1 big endian int, the number of longs in our bitset // N big endian longs of our bitset DataOutputStream dout = new DataOutputStream(out); dout.writeByte(SignedBytes.checkedCast(strategy.ordinal())); dout.writeByte(UnsignedBytes.checkedCast(numHashFunctions)); // note: checked at the c'tor dout.writeInt(bits.data.length()); for (int i = 0; i < bits.data.length(); i++) { dout.writeLong(bits.data.get(i)); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 23 16:45:30 UTC 2024 - 26.6K bytes - Viewed (0) -
android/guava/src/com/google/common/primitives/UnsignedInts.java
* @throws IllegalArgumentException if {@code value} is negative or greater than or equal to * 2<sup>32</sup> * @since 21.0 */ public static int checkedCast(long value) { checkArgument((value >> Integer.SIZE) == 0, "out of range: %s", value); return (int) value; } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 21:17:54 UTC 2024 - 13.7K bytes - Viewed (0) -
guava/src/com/google/common/primitives/UnsignedInts.java
* @throws IllegalArgumentException if {@code value} is negative or greater than or equal to * 2<sup>32</sup> * @since 21.0 */ public static int checkedCast(long value) { checkArgument((value >> Integer.SIZE) == 0, "out of range: %s", value); return (int) value; } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 21:17:54 UTC 2024 - 13.7K bytes - Viewed (0) -
guava-tests/test/com/google/common/hash/BloomFilterTest.java
@AndroidIncompatible // slow public void testBitSize() { double fpp = 0.03; for (int i = 1; i < 10000; i++) { long numBits = BloomFilter.optimalNumOfBits(i, fpp); int arraySize = Ints.checkedCast(LongMath.divide(numBits, 64, RoundingMode.CEILING)); assertEquals( arraySize * Long.SIZE, BloomFilter.create(Funnels.unencodedCharsFunnel(), i, fpp).bitSize()); } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Oct 21 14:28:19 UTC 2024 - 21.2K bytes - Viewed (0) -
android/guava/src/com/google/common/primitives/Chars.java
* @throws IllegalArgumentException if {@code value} is greater than {@link Character#MAX_VALUE} * or less than {@link Character#MIN_VALUE} */ public static char checkedCast(long value) { char result = (char) value; checkArgument(result == value, "Out of range: %s", value); return result; } /** * Returns the {@code char} nearest in value to {@code value}. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Aug 27 16:47:48 UTC 2024 - 23.9K bytes - Viewed (0) -
android/guava/src/com/google/common/primitives/Shorts.java
* @throws IllegalArgumentException if {@code value} is greater than {@link Short#MAX_VALUE} or * less than {@link Short#MIN_VALUE} */ public static short checkedCast(long value) { short result = (short) value; checkArgument(result == value, "Out of range: %s", value); return result; } /** * Returns the {@code short} nearest in value to {@code value}. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Aug 27 16:47:48 UTC 2024 - 25.5K bytes - Viewed (0) -
guava/src/com/google/common/primitives/Shorts.java
* @throws IllegalArgumentException if {@code value} is greater than {@link Short#MAX_VALUE} or * less than {@link Short#MIN_VALUE} */ public static short checkedCast(long value) { short result = (short) value; checkArgument(result == value, "Out of range: %s", value); return result; } /** * Returns the {@code short} nearest in value to {@code value}. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Aug 27 16:47:48 UTC 2024 - 25.5K bytes - Viewed (0)