Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 10 of 17 for HashFunction (0.06 seconds)

  1. guava-tests/test/com/google/common/hash/HashingTest.java

          if (shouldHaveKnownHashes(method)) {
            HashFunction hashFunction = (HashFunction) method.invoke(Hashing.class);
            assertTrue(
                "There should be at least 3 entries in KNOWN_HASHES for " + hashFunction,
                KNOWN_HASHES.row(hashFunction).size() >= 3);
          }
        }
      }
    
      public void testKnownUtf8Hashing() {
        for (Cell<HashFunction, String, String> cell : KNOWN_HASHES.cellSet()) {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Fri Mar 13 13:01:07 GMT 2026
    - 26.7K bytes
    - Click Count (2)
  2. android/guava-tests/test/com/google/common/hash/HashingOutputStreamTest.java

      private Hasher hasher;
      private HashFunction hashFunction;
      private final ByteArrayOutputStream buffer = new ByteArrayOutputStream();
    
      @SuppressWarnings("DoNotMock")
      @Override
      protected void setUp() throws Exception {
        super.setUp();
        hasher = mock(Hasher.class);
        hashFunction = mock(HashFunction.class);
    
        when(hashFunction.newHasher()).thenReturn(hasher);
      }
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 3.2K bytes
    - Click Count (0)
  3. android/guava-tests/test/com/google/common/hash/HashingInputStreamTest.java

      private Hasher hasher;
      private HashFunction hashFunction;
      private static final byte[] testBytes = new byte[] {'y', 'a', 'm', 's'};
      private ByteArrayInputStream buffer;
    
      @SuppressWarnings("DoNotMock")
      @Override
      protected void setUp() throws Exception {
        super.setUp();
        hasher = mock(Hasher.class);
        hashFunction = mock(HashFunction.class);
        buffer = new ByteArrayInputStream(testBytes);
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 5.1K bytes
    - Click Count (0)
  4. guava-tests/test/com/google/common/hash/HashingInputStreamTest.java

      private Hasher hasher;
      private HashFunction hashFunction;
      private static final byte[] testBytes = new byte[] {'y', 'a', 'm', 's'};
      private ByteArrayInputStream buffer;
    
      @SuppressWarnings("DoNotMock")
      @Override
      protected void setUp() throws Exception {
        super.setUp();
        hasher = mock(Hasher.class);
        hashFunction = mock(HashFunction.class);
        buffer = new ByteArrayInputStream(testBytes);
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 5.1K bytes
    - Click Count (0)
  5. android/guava-tests/test/com/google/common/hash/HashFunctionEnum.java

      // These can probably be removed sooner or later.
      ;
    
      private final HashFunction hashFunction;
    
      HashFunctionEnum(HashFunction hashFunction) {
        this.hashFunction = hashFunction;
      }
    
      HashFunction getHashFunction() {
        return hashFunction;
      }
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 2.4K bytes
    - Click Count (0)
  6. guava-tests/test/com/google/common/hash/HashingOutputStreamTest.java

      private Hasher hasher;
      private HashFunction hashFunction;
      private final ByteArrayOutputStream buffer = new ByteArrayOutputStream();
    
      @SuppressWarnings("DoNotMock")
      @Override
      protected void setUp() throws Exception {
        super.setUp();
        hasher = mock(Hasher.class);
        hashFunction = mock(HashFunction.class);
    
        when(hashFunction.newHasher()).thenReturn(hasher);
      }
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 3.2K bytes
    - Click Count (0)
  7. guava-tests/test/com/google/common/hash/HashFunctionEnum.java

      // These can probably be removed sooner or later.
      ;
    
      private final HashFunction hashFunction;
    
      HashFunctionEnum(HashFunction hashFunction) {
        this.hashFunction = hashFunction;
      }
    
      HashFunction getHashFunction() {
        return hashFunction;
      }
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 2.4K bytes
    - Click Count (0)
  8. android/guava-tests/test/com/google/common/hash/ChecksumHashFunctionTest.java

        byte[] bytes = HashTestUtils.ascii(input);
    
        Checksum checksum = supplier.get();
        checksum.update(bytes, 0, bytes.length);
        long value = checksum.getValue();
    
        String toString = "name";
        HashFunction func = new ChecksumHashFunction(supplier, 32, toString);
        assertThat(func.toString()).isEqualTo(toString);
        assertEquals(value, func.hashBytes(bytes).padToLong());
      }
    
      private static void assertHash32(
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 12 17:47:10 GMT 2026
    - 3.3K bytes
    - Click Count (0)
  9. android/guava-tests/test/com/google/common/hash/MessageDigestHashFunctionTest.java

      //  - The algorithm name is not case-sensitive.
      @SuppressWarnings("deprecation") // We still need to test our deprecated APIs.
      private static final ImmutableMap<String, HashFunction> ALGORITHMS =
          new ImmutableMap.Builder<String, HashFunction>()
              .put("MD5", md5())
              .put("SHA", sha1()) // Not the official name, but still works
              .put("SHA1", sha1()) // Not the official name, but still works
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 4.9K bytes
    - Click Count (0)
  10. guava-tests/test/com/google/common/hash/MacHashFunctionTest.java

      // https://docs.oracle.com/en/java/javase/25/docs/specs/security/standard-names.html#mac-algorithms
      private static final ImmutableTable<String, SecretKey, HashFunction> ALGORITHMS =
          new ImmutableTable.Builder<String, SecretKey, HashFunction>()
              .put("HmacMD5", MD5_KEY, hmacMd5(MD5_KEY))
              .put("HmacSHA1", SHA1_KEY, hmacSha1(SHA1_KEY))
              .put("HmacSHA256", SHA256_KEY, hmacSha256(SHA256_KEY))
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 19 18:53:45 GMT 2026
    - 14.2K bytes
    - Click Count (0)
Back to Top