- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 41 for newHasher (0.09 sec)
-
android/guava-tests/test/com/google/common/hash/MessageDigestHashFunctionTest.java
Hasher sha1 = Hashing.sha1().newHasher(); assertEquals( "2fd4e1c67a2d28fced849ee1bb76e7391b93eb12", sha1.putString("The quick brown fox jumps over the lazy dog", UTF_8).hash().toString()); assertThrows(IllegalStateException.class, () -> sha1.putInt(42)); } public void testHashTwice() { Hasher sha1 = Hashing.sha1().newHasher(); assertEquals(
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Jul 23 14:22:54 UTC 2024 - 4.1K bytes - Viewed (0) -
android/guava-tests/benchmark/com/google/common/hash/MessageDigestAlgorithmBenchmark.java
} }, HASH_FUNCTION_VIA_HASHER() { @Override public byte[] hash(Algorithm algorithm, byte[] input) { return algorithm.getHashFunction().newHasher().putBytes(input).hash().asBytes(); } }; ; public abstract byte[] hash(Algorithm algorithm, byte[] input); } private enum Algorithm { MD5("MD5", Hashing.md5()),
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Dec 04 17:37:03 UTC 2017 - 3.5K bytes - Viewed (0) -
guava-tests/benchmark/com/google/common/hash/MessageDigestAlgorithmBenchmark.java
} }, HASH_FUNCTION_VIA_HASHER() { @Override public byte[] hash(Algorithm algorithm, byte[] input) { return algorithm.getHashFunction().newHasher().putBytes(input).hash().asBytes(); } }; ; public abstract byte[] hash(Algorithm algorithm, byte[] input); } private enum Algorithm { MD5("MD5", Hashing.md5()),
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Dec 04 17:37:03 UTC 2017 - 3.5K bytes - Viewed (0) -
guava/src/com/google/common/hash/ChecksumHashFunction.java
this.bits = bits; this.toString = checkNotNull(toString); } @Override public int bits() { return bits; } @Override public Hasher newHasher() { return new ChecksumHasher(checksumSupplier.get()); } @Override public String toString() { return toString; } /** Hasher that updates a checksum. */
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 13:05:16 UTC 2024 - 4.6K bytes - Viewed (0) -
android/guava/src/com/google/common/hash/HashingOutputStream.java
// MultiplexingOutputStream). public HashingOutputStream(HashFunction hashFunction, OutputStream out) { super(checkNotNull(out)); this.hasher = checkNotNull(hashFunction.newHasher()); } @Override public void write(int b) throws IOException { hasher.putByte((byte) b); out.write(b); } @Override
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 11 22:00:03 UTC 2024 - 2.6K bytes - Viewed (0) -
android/guava/src/com/google/common/hash/SipHashFunction.java
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Apr 20 18:43:59 UTC 2021 - 5.3K bytes - Viewed (0) -
guava/src/com/google/common/hash/MacHashFunction.java
} catch (NoSuchAlgorithmException e) { throw new IllegalStateException(e); } catch (InvalidKeyException e) { throw new IllegalArgumentException(e); } } @Override public Hasher newHasher() { if (supportsClone) { try { return new MacHasher((Mac) prototype.clone()); } catch (CloneNotSupportedException e) { // falls through } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Feb 15 22:31:55 UTC 2022 - 3.6K bytes - Viewed (0) -
android/guava/src/com/google/common/hash/MessageDigestHashFunction.java
try { return MessageDigest.getInstance(algorithmName); } catch (NoSuchAlgorithmException e) { throw new AssertionError(e); } } @Override public Hasher newHasher() { if (supportsClone) { try { return new MessageDigestHasher((MessageDigest) prototype.clone(), bytes); } catch (CloneNotSupportedException e) { // falls through } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed May 25 20:32:46 UTC 2022 - 5K bytes - Viewed (0) -
guava/src/com/google/common/hash/MessageDigestHashFunction.java
try { return MessageDigest.getInstance(algorithmName); } catch (NoSuchAlgorithmException e) { throw new AssertionError(e); } } @Override public Hasher newHasher() { if (supportsClone) { try { return new MessageDigestHasher((MessageDigest) prototype.clone(), bytes); } catch (CloneNotSupportedException e) { // falls through } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed May 25 20:32:46 UTC 2022 - 5K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/hash/AbstractStreamingHasherTest.java
// passes, and there is still a little endianness bug lurking around. } } Control control = new Control(); Hasher controlSink = control.newHasher(1024); Iterable<Hasher> sinksAndControl = Iterables.concat(sinks, Collections.singleton(controlSink)); for (int insertion = 0; insertion < totalInsertions; insertion++) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Jul 23 14:22:54 UTC 2024 - 8.5K bytes - Viewed (0)