- Sort Score
- Result 10 results
- Languages All
Results 61 - 70 of 113 for ClassCastException (0.42 sec)
-
android/guava-tests/test/com/google/common/collect/MutableClassToInstanceMapTest.java
* well-tested. A purist would object to this, but what can I say, we're dirty cheaters. */ map.put(Integer.class, new Integer(5)); assertThrows(ClassCastException.class, () -> map.put(Double.class, new Long(42))); // Won't compile: map.put(String.class, "x"); } public void testPutAndGetInstance() { assertNull(map.putInstance(Integer.class, new Integer(5)));
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Feb 22 20:09:59 UTC 2024 - 4.8K bytes - Viewed (0) -
guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ForwardingImmutableMap.java
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Jan 24 16:03:45 UTC 2024 - 3.9K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/testers/MapRemoveTester.java
expectUnchanged(); } @MapFeature.Require(SUPPORTS_REMOVE) public void testRemove_wrongType() { try { assertNull(getMap().remove(WrongType.VALUE)); } catch (ClassCastException tolerated) { } expectUnchanged(); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 20:00:30 UTC 2024 - 5.8K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/testers/MapReplaceEntryTester.java
@CollectionSize.Require(absent = ZERO) public void testReplaceEntry_supportedPresent() { try { assertTrue(getMap().replace(k0(), v0(), v3())); expectReplacement(entry(k0(), v3())); } catch (ClassCastException tolerated) { // for ClassToInstanceMap expectUnchanged(); } } @MapFeature.Require(SUPPORTS_PUT) @CollectionSize.Require(absent = ZERO)
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 31 14:51:04 UTC 2024 - 5.4K bytes - Viewed (0) -
docs/changelogs/changelog_1x.md
``` * Improve cache invalidation for POST-like requests. * Bring MockWebServer into OkHttp and teach it SPDY. ## Version 1.1.1 _2013-06-23_ * Fix: ClassCastException when caching responses that were redirected from HTTP to HTTPS. ## Version 1.1.0 _2013-06-15_ * Fix: Connection reuse was broken for most HTTPS connections due to a bug in
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Feb 06 02:19:09 UTC 2022 - 6.4K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/AbstractTableTest.java
} } @SuppressWarnings("unchecked") // C can only be @Nullable Character or Character protected @NonNull C cellValue(Character character) { return (C) character; } // Only safe wrt. ClassCastException. Not null-safe (can be used to test expected Table NPEs) @SuppressWarnings("unchecked") protected C nullableCellValue(@Nullable Character character) { return (C) character; }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Oct 15 17:36:06 UTC 2024 - 5.8K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/testers/CollectionRemoveAllTester.java
try { assertFalse( "removeAll(containsWrongType) should return false or throw", collection.removeAll(MinimalCollection.of(WrongType.VALUE))); } catch (ClassCastException tolerated) { } expectUnchanged(); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 7.6K bytes - Viewed (0) -
guava/src/com/google/common/collect/ForwardingSortedMap.java
SortedMap<@Nullable Object, V> self = (SortedMap<@Nullable Object, V>) this; Object ceilingKey = self.tailMap(key).firstKey(); return unsafeCompare(comparator(), ceilingKey, key) == 0; } catch (ClassCastException | NoSuchElementException | NullPointerException e) { return false; } } /** * A sensible default implementation of {@link #subMap(Object, Object)} in terms of {@link
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri May 12 15:26:39 UTC 2023 - 5.6K bytes - Viewed (0) -
guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ImmutableSortedSet.java
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Aug 19 16:21:24 UTC 2024 - 15.5K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/SafeTreeSet.java
return delegate.toArray(); } @Override public <T> T[] toArray(T[] a) { return delegate.toArray(a); } @CanIgnoreReturnValue private <T> T checkValid(T t) { // a ClassCastException is what's supposed to happen! @SuppressWarnings("unchecked") E e = (E) t; int unused = comparator().compare(e, e); return t; } @Override
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Feb 20 17:00:05 UTC 2024 - 5.8K bytes - Viewed (0)