Searched refs:UnsignedBytes (Results 1 – 7 of 7) sorted by relevance
44 assertEquals(0, UnsignedBytes.toInt((byte) 0)); in testToInt()45 assertEquals(1, UnsignedBytes.toInt((byte) 1)); in testToInt()46 assertEquals(127, UnsignedBytes.toInt((byte) 127)); in testToInt()47 assertEquals(128, UnsignedBytes.toInt((byte) -128)); in testToInt()48 assertEquals(129, UnsignedBytes.toInt((byte) -127)); in testToInt()49 assertEquals(255, UnsignedBytes.toInt((byte) -1)); in testToInt()55 UnsignedBytes.checkedCast(UnsignedBytes.toInt(value))); in testCheckedCast()66 UnsignedBytes.saturatedCast(UnsignedBytes.toInt(value))); in testSaturatedCast()68 assertEquals(GREATEST, UnsignedBytes.saturatedCast(256L)); in testSaturatedCast()69 assertEquals(LEAST, UnsignedBytes.saturatedCast(-1L)); in testSaturatedCast()[all …]
44 public final class UnsignedBytes { class45 private UnsignedBytes() {} in UnsignedBytes() method in UnsignedBytes294 int result = UnsignedBytes.compare(left[i], right[i]); in compare()
26 import com.google.common.primitives.UnsignedBytes;425 dout.writeByte(UnsignedBytes.checkedCast(numHashFunctions)); // note: checked at the c'tor456 numHashFunctions = UnsignedBytes.toInt(din.readByte());
28 import static com.google.common.primitives.UnsignedBytes.toInt;
8 Remove usages of Unsafe in UnsignedBytes.java and use standard Java
57 javaImpl = UnsignedBytes.lexicographicalComparatorJavaImpl(); in setUp()