- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 34 for buildOrThrow (0.07 sec)
-
android/guava-tests/test/com/google/common/collect/ImmutableMapTest.java
public void testEmptyBuilder() { ImmutableMap<String, Integer> map = new Builder<String, Integer>().buildOrThrow(); assertEquals(Collections.<String, Integer>emptyMap(), map); } public void testSingletonBuilder() { ImmutableMap<String, Integer> map = new Builder<String, Integer>().put("one", 1).buildOrThrow(); assertMapEquals(map, "one", 1); } public void testBuilder() {
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 36.7K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/google/MapGenerators.java
for (Entry<String, String> entry : entries) { checkNotNull(entry); builder.put(entry.getKey(), entry.getValue()); } return builder.buildOrThrow(); } } public static class ImmutableMapCopyOfGenerator extends TestStringMapGenerator { @Override protected Map<String, String> create(Entry<String, String>[] entries) {
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Sun Aug 10 19:54:19 UTC 2025 - 8.6K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/google/MapGenerators.java
for (Entry<String, String> entry : entries) { checkNotNull(entry); builder.put(entry.getKey(), entry.getValue()); } return builder.buildOrThrow(); } } public static class ImmutableMapCopyOfGenerator extends TestStringMapGenerator { @Override protected Map<String, String> create(Entry<String, String>[] entries) {
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Sun Aug 10 19:54:19 UTC 2025 - 8.6K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableMap.java
@Nullable Object[] alternatingKeysAndValues; int size; boolean entriesUsed; /** * If non-null, a duplicate key we found in a previous buildKeepingLast() or buildOrThrow() * call. A later buildOrThrow() can simply report this duplicate immediately. */ @Nullable DuplicateKey duplicateKey; /**
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Sat Aug 09 01:14:59 UTC 2025 - 41.2K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/TableCollectorsTest.java
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 12.5K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/google/ReflectionFreeAssertThrows.java
.put(VerifyException.class, e -> e instanceof VerifyException) .putAll(PlatformSpecificExceptionBatch.PLATFORM.exceptions()) .buildOrThrow(); private ReflectionFreeAssertThrows() {}
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 6.3K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/RegularImmutableMap.java
* Builder.buildKeepingLast(). The same Builder might be called with buildKeepingLast() and then * buildOrThrow(), or vice versa. So in particular, if we modify alternatingKeysAndValues to * eliminate duplicate keys (for buildKeepingLast()) then we have to ensure that a later call to * buildOrThrow() will still throw as if the duplicates had not been eliminated. And the exception
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Sat Aug 09 01:14:59 UTC 2025 - 22.5K bytes - Viewed (0) -
guava/src/com/google/common/collect/ImmutableMap.java
* * <p>Prefer the equivalent method {@link #buildOrThrow()} to make it explicit that the method * will throw an exception if there are duplicate keys. The {@code build()} method will soon be * deprecated. * * @throws IllegalArgumentException if duplicate keys were added */ public ImmutableMap<K, V> build() { return buildOrThrow(); } /**
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Sat Aug 09 01:14:59 UTC 2025 - 44.3K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableBiMap.java
* <p>Prefer the equivalent method {@link #buildOrThrow()} to make it explicit that the method * will throw an exception if there are duplicate keys or values. The {@code build()} method * will soon be deprecated. * * @throws IllegalArgumentException if duplicate keys or values were added */ @Override public ImmutableBiMap<K, V> build() { return buildOrThrow(); } /**
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 22.2K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableListMultimap.java
if (!list.isEmpty()) { builder.put(key, list); size += list.size(); } } return new ImmutableListMultimap<>(builder.buildOrThrow(), size); } /** Creates an ImmutableListMultimap from an asMap.entrySet. */ static <K, V> ImmutableListMultimap<K, V> fromMapBuilderEntries(
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 19K bytes - Viewed (0)