Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for newHashMapWithExpectedSize (0.08 sec)

  1. guava/src/com/google/common/collect/ArrayListMultimap.java

      }
    
      private ArrayListMultimap() {
        this(12, DEFAULT_VALUES_PER_KEY);
      }
    
      private ArrayListMultimap(int expectedKeys, int expectedValuesPerKey) {
        super(Platform.newHashMapWithExpectedSize(expectedKeys));
        checkNonnegative(expectedValuesPerKey, "expectedValuesPerKey");
        this.expectedValuesPerKey = expectedValuesPerKey;
      }
    
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Fri Dec 05 23:15:58 UTC 2025
    - 6.8K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/collect/MapsTest.java

        // after  jdk7u40: creates empty table
        assertThat(bucketsOf(Maps.newHashMapWithExpectedSize(0))).isAtMost(1);
    
        for (int size = 1; size < 200; size++) {
          assertWontGrow(
              size,
              new HashMap<>(),
              Maps.newHashMapWithExpectedSize(size),
              Maps.newHashMapWithExpectedSize(size));
        }
      }
    
      /** Same test as above but for newLinkedHashMapWithExpectedSize */
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Thu Dec 11 22:56:33 UTC 2025
    - 62.7K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/collect/MapsTest.java

        // after  jdk7u40: creates empty table
        assertThat(bucketsOf(Maps.newHashMapWithExpectedSize(0))).isAtMost(1);
    
        for (int size = 1; size < 200; size++) {
          assertWontGrow(
              size,
              new HashMap<>(),
              Maps.newHashMapWithExpectedSize(size),
              Maps.newHashMapWithExpectedSize(size));
        }
      }
    
      /** Same test as above but for newLinkedHashMapWithExpectedSize */
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Thu Dec 11 22:56:33 UTC 2025
    - 65K bytes
    - Viewed (0)
  4. guava/src/com/google/common/collect/Maps.java

       */
      @SuppressWarnings("NonApiType") // acts as a direct substitute for a constructor call
      public static <K extends @Nullable Object, V extends @Nullable Object>
          HashMap<K, V> newHashMapWithExpectedSize(int expectedSize) {
        return new HashMap<>(capacity(expectedSize));
      }
    
      /**
       * Returns a capacity that is sufficient to keep the map from being resized as long as it grows no
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Nov 17 22:50:48 UTC 2025
    - 163.5K bytes
    - Viewed (0)
Back to top