Search Options

Results per page
Sort
Preferred Languages
Advance

Results 231 - 240 of 344 for NullPointerException (0.12 sec)

  1. android/guava-tests/test/com/google/common/collect/RangeTest.java

      public void testEncloseAll_nullValue() {
        List<@Nullable Integer> nullFirst = Lists.newArrayList(null, 0);
        assertThrows(NullPointerException.class, () -> Range.encloseAll((List<Integer>) nullFirst));
        List<@Nullable Integer> nullNotFirst = Lists.newArrayList(0, null);
        assertThrows(NullPointerException.class, () -> Range.encloseAll((List<Integer>) nullNotFirst));
      }
    
      public void testEquivalentFactories() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 23.9K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/primitives/Booleans.java

       *
       * @param collection a collection of {@code Boolean} objects
       * @return an array containing the same values as {@code collection}, in the same order, converted
       *     to primitives
       * @throws NullPointerException if {@code collection} or any of its elements is null
       */
      public static boolean[] toArray(Collection<Boolean> collection) {
        if (collection instanceof BooleanArrayAsList) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 19:07:49 UTC 2024
    - 20.4K bytes
    - Viewed (0)
  3. guava/src/com/google/common/primitives/Booleans.java

       *
       * @param collection a collection of {@code Boolean} objects
       * @return an array containing the same values as {@code collection}, in the same order, converted
       *     to primitives
       * @throws NullPointerException if {@code collection} or any of its elements is null
       */
      public static boolean[] toArray(Collection<Boolean> collection) {
        if (collection instanceof BooleanArrayAsList) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 19:07:49 UTC 2024
    - 20.4K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/Maps.java

       * NullPointerException}.
       */
      @CheckForNull
      static <V extends @Nullable Object> V safeGet(Map<?, V> map, @CheckForNull Object key) {
        checkNotNull(map);
        try {
          return map.get(key);
        } catch (ClassCastException | NullPointerException e) {
          return null;
        }
      }
    
      /**
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 161.6K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/Maps.java

       * NullPointerException}.
       */
      @CheckForNull
      static <V extends @Nullable Object> V safeGet(Map<?, V> map, @CheckForNull Object key) {
        checkNotNull(map);
        try {
          return map.get(key);
        } catch (ClassCastException | NullPointerException e) {
          return null;
        }
      }
    
      /**
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 167.4K bytes
    - Viewed (0)
  6. android/guava-testlib/src/com/google/common/collect/testing/google/MultimapGetTester.java

      public void testGetNullAbsent() {
        assertEmpty(multimap().get(null));
      }
    
      @MapFeature.Require(absent = ALLOWS_NULL_KEY_QUERIES)
      public void testGetNullForbidden() {
        assertThrows(NullPointerException.class, () -> multimap().get(null));
      }
    
      @MapFeature.Require(ALLOWS_NULL_VALUES)
      @CollectionSize.Require(absent = ZERO)
      public void testGetWithNullValue() {
        initMultimapWithNullValue();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 5.6K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/MoreCollectors.java

      /**
       * A collector that converts a stream of zero or one elements to an {@code Optional}.
       *
       * @throws IllegalArgumentException if the stream consists of two or more elements.
       * @throws NullPointerException if any element in the stream is {@code null}.
       * @return {@code Optional.of(onlyElement)} if the stream has exactly one element (must not be
       *     {@code null}) and returns {@code Optional.empty()} if it has none.
       */
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 16 21:21:17 UTC 2024
    - 5.6K bytes
    - Viewed (0)
  8. guava-testlib/src/com/google/common/collect/testing/google/MultimapAsMapTester.java

        assertNull(multimap().asMap().get(null));
      }
    
      @MapFeature.Require(absent = ALLOWS_NULL_KEY_QUERIES)
      public void testAsMapGetNullKeyUnsupported() {
        assertThrows(NullPointerException.class, () -> multimap().asMap().get(null));
      }
    
      @CollectionSize.Require(absent = ZERO)
      @MapFeature.Require(SUPPORTS_REMOVE)
      public void testAsMapRemove() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/collect/testing/google/MultimapAsMapTester.java

        assertNull(multimap().asMap().get(null));
      }
    
      @MapFeature.Require(absent = ALLOWS_NULL_KEY_QUERIES)
      public void testAsMapGetNullKeyUnsupported() {
        assertThrows(NullPointerException.class, () -> multimap().asMap().get(null));
      }
    
      @CollectionSize.Require(absent = ZERO)
      @MapFeature.Require(SUPPORTS_REMOVE)
      public void testAsMapRemove() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  10. okhttp/src/main/kotlin/okhttp3/Cookie.kt

            this.sameSite = sameSite
          }
    
        fun build(): Cookie {
          return Cookie(
            name ?: throw NullPointerException("builder.name == null"),
            value ?: throw NullPointerException("builder.value == null"),
            expiresAt,
            domain ?: throw NullPointerException("builder.domain == null"),
            path,
            secure,
            httpOnly,
            persistent,
            hostOnly,
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 06 04:12:05 UTC 2024
    - 23.1K bytes
    - Viewed (0)
Back to top