Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 30 for collision (0.15 sec)

  1. android/guava/src/com/google/common/cache/Striped64.java

       * which is still better than alternatives.
       *
       * Per-thread hash codes are initialized to random values.
       * Contention and/or table collisions are indicated by failed
       * CASes when performing an update operation (see method
       * retryUpdate). Upon a collision, if the table size is less than
       * the capacity, it is doubled in size unless some other thread
       * holds the lock. If a hashed slot is empty, and lock is
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Wed Jan 15 22:17:15 UTC 2025
    - 11.4K bytes
    - Viewed (0)
  2. src/test/java/jcifs/internal/smb2/Smb2EncryptionContextTest.java

        }
    
        @Test
        @DisplayName("Should generate multiple unique nonces without collision")
        void testGenerateMultipleNoncesNoCollision() {
            // Given
            int count = 10000; // Test with larger number for collision detection
            Set<String> nonceSet = new HashSet<>();
    
            // When
            for (int i = 0; i < count; i++) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sun Aug 31 08:00:57 UTC 2025
    - 44.1K bytes
    - Viewed (0)
  3. guava-testlib/src/com/google/common/testing/ClassSanityTester.java

            // probably intended. So no point in using an equal-but-different factory argument.
            // We check twice to avoid confusion caused by accidental hash collision.
            equalArgs.set(i, shouldBeEqualArg);
          }
        }
        return equalArgs;
      }
    
      private static boolean hashCodeInsensitiveToArgReference(
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sat Aug 09 01:14:59 UTC 2025
    - 32.5K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/collect/MapMakerInternalMapTest.java

        assertSame(value, segment.get(key, hash));
        assertTrue(segment.containsKey(key, hash));
        assertTrue(segment.containsValue(value));
        assertFalse(segment.containsValue(nullValue));
    
        // hash collision
        InternalEntry<Object, Object, ?> dummyEntry =
            segment.newEntryForTesting(new Object(), hash, entry);
        Object dummyValue = new Object();
        WeakValueReference<Object, Object, ?> dummyValueRef =
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 35.1K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/collect/MapMakerInternalMapTest.java

        assertSame(value, segment.get(key, hash));
        assertTrue(segment.containsKey(key, hash));
        assertTrue(segment.containsValue(value));
        assertFalse(segment.containsValue(nullValue));
    
        // hash collision
        InternalEntry<Object, Object, ?> dummyEntry =
            segment.newEntryForTesting(new Object(), hash, entry);
        Object dummyValue = new Object();
        WeakValueReference<Object, Object, ?> dummyValueRef =
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 35.1K bytes
    - Viewed (0)
  6. guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ImmutableSortedMap.java

          SortedMap<K, V> map, Entry<? extends K, ? extends V> entry) {
        K key = checkNotNull(entry.getKey());
        V value = checkNotNull(entry.getValue());
        if (map.containsKey(key)) {
          // When a collision happens, the colliding entry is the first entry
          // of the tail map.
          Entry<K, V> previousEntry = map.tailMap(key).entrySet().iterator().next();
          throw new IllegalArgumentException(
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Wed Aug 06 18:32:41 UTC 2025
    - 16.1K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/cache/LocalCacheTest.java

        assertSame(value, segment.get(key, hash));
        assertTrue(segment.containsKey(key, hash));
        assertTrue(segment.containsValue(value));
        assertFalse(segment.containsValue(nullValue));
    
        // hash collision
        DummyEntry<Object, Object> dummy = DummyEntry.create(new Object(), hash, entry);
        Object dummyValue = new Object();
        ValueReference<Object, Object> dummyValueRef = map.newValueReference(dummy, dummyValue, 1);
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Mon Aug 11 19:31:30 UTC 2025
    - 110.5K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/hash/HashTestUtils.java

              assertThat(prob).isWithin(epsilon).of(0.50d);
            }
          }
        }
      }
    
      /**
       * Checks that a Hasher returns the same HashCode when given the same input, and also that the
       * collision rate looks sane.
       */
      static void assertInvariants(HashFunction hashFunction) {
        int objects = 100;
        Set<HashCode> hashcodes = Sets.newHashSetWithExpectedSize(objects);
        Random random = new Random(314159);
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Mon Aug 11 19:31:30 UTC 2025
    - 25.6K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/testing/ClassSanityTester.java

            // probably intended. So no point in using an equal-but-different factory argument.
            // We check twice to avoid confusion caused by accidental hash collision.
            equalArgs.set(i, shouldBeEqualArg);
          }
        }
        return equalArgs;
      }
    
      private static boolean hashCodeInsensitiveToArgReference(
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sat Aug 09 01:14:59 UTC 2025
    - 32.5K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/base/CharMatcher.java

        // TABLE is a precomputed hashset of whitespace characters. MULTIPLIER serves as a hash function
        // whose key property is that it maps 25 characters into the 32-slot table without collision.
        // Basically this is an opportunistic fast implementation as opposed to "good code". For most
        // other use-cases, the reduction in readability isn't worth it.
        static final String TABLE =
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 53.9K bytes
    - Viewed (0)
Back to top