Search Options

Results per page
Sort
Preferred Languages
Advance

Results 251 - 260 of 344 for NullPointerException (0.16 sec)

  1. android/guava-testlib/src/com/google/common/collect/testing/google/MultimapPutTester.java

        assertEquals(size + 1, multimap().size());
      }
    
      @MapFeature.Require(value = SUPPORTS_PUT, absent = ALLOWS_NULL_VALUES)
      public void testPutNullValue_unsupported() {
        assertThrows(NullPointerException.class, () -> multimap().put(k1(), null));
    
        expectUnchanged();
      }
    
      @MapFeature.Require({SUPPORTS_PUT, ALLOWS_NULL_KEYS})
      public void testPutNullKey() {
        int size = getNumElements();
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 7.2K bytes
    - Viewed (0)
  2. guava-testlib/src/com/google/common/testing/EqualsTester.java

        List<Object> list = new ArrayList<>(equalityGroup.length);
        for (int i = 0; i < equalityGroup.length; i++) {
          Object element = equalityGroup[i];
          if (element == null) {
            throw new NullPointerException("at index " + i);
          }
          list.add(element);
        }
        equalityGroups.add(list);
        return this;
      }
    
      /** Run tests on equals method, throwing a failure on an invalid test */
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 31 19:11:50 UTC 2023
    - 6K bytes
    - Viewed (0)
  3. guava-testlib/src/com/google/common/collect/testing/google/MultimapPutTester.java

        assertEquals(size + 1, multimap().size());
      }
    
      @MapFeature.Require(value = SUPPORTS_PUT, absent = ALLOWS_NULL_VALUES)
      public void testPutNullValue_unsupported() {
        assertThrows(NullPointerException.class, () -> multimap().put(k1(), null));
    
        expectUnchanged();
      }
    
      @MapFeature.Require({SUPPORTS_PUT, ALLOWS_NULL_KEYS})
      public void testPutNullKey() {
        int size = getNumElements();
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 7.2K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/util/concurrent/SequentialExecutorTest.java

      @Override
      public void setUp() {
        fakePool = new FakeExecutor();
        e = new SequentialExecutor(fakePool);
      }
    
      public void testConstructingWithNullExecutor_fails() {
        assertThrows(NullPointerException.class, () -> new SequentialExecutor(null));
      }
    
      public void testBasics() {
        final AtomicInteger totalCalls = new AtomicInteger();
        Runnable intCounter =
            new Runnable() {
              @Override
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 22:10:29 UTC 2024
    - 11.4K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/collect/OrderingTest.java

        testComparator(comparator, Integer.MIN_VALUE, -1, 0, 1, Integer.MAX_VALUE);
        assertThrows(NullPointerException.class, () -> comparator.compare(1, null));
        assertThrows(NullPointerException.class, () -> comparator.compare(null, 2));
        assertThrows(NullPointerException.class, () -> comparator.compare(null, null));
        assertSame(comparator, reserialize(comparator));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 42.6K bytes
    - Viewed (0)
  6. guava-tests/test/com/google/common/collect/OrderingTest.java

        testComparator(comparator, Integer.MIN_VALUE, -1, 0, 1, Integer.MAX_VALUE);
        assertThrows(NullPointerException.class, () -> comparator.compare(1, null));
        assertThrows(NullPointerException.class, () -> comparator.compare(null, 2));
        assertThrows(NullPointerException.class, () -> comparator.compare(null, null));
        assertSame(comparator, reserialize(comparator));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 42.6K bytes
    - Viewed (0)
  7. guava/src/com/google/common/collect/Streams.java

       * streams.
       *
       * <p>If the stream has nondeterministic order, this has equivalent semantics to {@link
       * Stream#findAny} (which you might as well use).
       *
       * @see Stream#findFirst()
       * @throws NullPointerException if the last element of the stream is null
       */
      /*
       * By declaring <T> instead of <T extends @Nullable Object>, we declare this method as requiring a
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 31 14:20:11 UTC 2024
    - 36.8K bytes
    - Viewed (0)
  8. guava/src/com/google/common/primitives/Bytes.java

       *
       * @param collection a collection of {@code Number} instances
       * @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
       * @since 1.0 (parameter was {@code Collection<Byte>} before 12.0)
       */
      public static byte[] toArray(Collection<? extends Number> collection) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Aug 27 16:47:48 UTC 2024
    - 15.3K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/primitives/DoublesTest.java

            }
          }
        }
      }
    
      public void testToArray_withNull() {
        List<@Nullable Double> list = Arrays.asList((double) 0, (double) 1, null);
        assertThrows(NullPointerException.class, () -> Doubles.toArray(list));
      }
    
      public void testToArray_withConversion() {
        double[] array = {(double) 0, (double) 1, (double) 2};
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 32.2K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/primitives/Chars.java

       *
       * @param collection a collection of {@code Character} 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 char[] toArray(Collection<Character> collection) {
        if (collection instanceof CharArrayAsList) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Aug 27 16:47:48 UTC 2024
    - 23.9K bytes
    - Viewed (0)
Back to top