@Test public void readZero() throws IOException { InputStream given = new ByteArrayInputStream(new UINT128(BigInteger.valueOf(0)).bytes()); UINT128 expected = new UINT128(BigInteger.valueOf(0)); UINT128 actual = UINT128.read(given); assertThat(actual, is(expected)); }
public static UINT128 read(InputStream is) throws IOException { byte[] bytes = new byte[SIZE_IN_BYTES]; if (is.read(bytes) != SIZE_IN_BYTES) { throw new EOFException(); } return new UINT128(bytes); }
UINT128 extends PtpInteger { public static UINT128 read(InputStream is) throws IOException { byte[] bytes = new byte[SIZE_IN_BYTES]; if (is.read(bytes) != SIZE_IN_BYTES) { throw new EOFException(); } return new UINT128(bytes); } }
UINT128 extends PtpInteger { public static UINT128 read(InputStream is) throws IOException { byte[] bytes = new byte[SIZE_IN_BYTES]; if (is.read(bytes) != SIZE_IN_BYTES) { throw new EOFException(); } return new UINT128(bytes); } UINT128(long value);  UINT128(BigInteger value);  UINT128(byte[] bytes); }
UINT128 extends PtpInteger { public static UINT128 read(InputStream is) throws IOException { byte[] bytes = new byte[SIZE_IN_BYTES]; if (is.read(bytes) != SIZE_IN_BYTES) { throw new EOFException(); } return new UINT128(bytes); } UINT128(long value);  UINT128(BigInteger value);  UINT128(byte[] bytes); static UINT128 read(InputStream is); }
UINT128 extends PtpInteger { public static UINT128 read(InputStream is) throws IOException { byte[] bytes = new byte[SIZE_IN_BYTES]; if (is.read(bytes) != SIZE_IN_BYTES) { throw new EOFException(); } return new UINT128(bytes); } UINT128(long value);  UINT128(BigInteger value);  UINT128(byte[] bytes); static UINT128 read(InputStream is); static final int SIZE_IN_BYTES; static final UINT128 MIN_VALUE; static final UINT128 MAX_VALUE; static final UINT128 ZERO; }