Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 1,258 for nulla (0.2 sec)

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

        int expectedHashCode = 0;
        for (E element : elements) {
          expectedHashCode += ((element == null) ? 0 : element.hashCode());
        }
    
        elements.add(null);
        collection = getSubjectGenerator().create(elements.toArray());
        assertEquals(
            "A Set's hashCode() should be the sum of those of its elements (with "
                + "a null element counting as having a hash of zero).",
            expectedHashCode,
            getSet().hashCode());
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 3K bytes
    - Viewed (0)
  2. guava-testlib/test/com/google/common/collect/testing/MapTestSuiteBuilderTests.java

              }
            },
            "HashMap w/out null keys",
            ALLOWS_NULL_VALUES);
      }
    
      private static Test testsForHashMapNullValuesForbidden() {
        return wrappedHashMapTests(
            new WrappedHashMapGenerator() {
              @Override
              Map<String, String> wrap(final HashMap<String, String> map) {
                if (map.containsValue(null)) {
                  throw new NullPointerException();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Apr 19 19:24:36 GMT 2023
    - 11.9K bytes
    - Viewed (0)
  3. guava/src/com/google/common/collect/ImmutableMultiset.java

       *
       * @throws NullPointerException if {@code element} is null
       * @since 6.0 (source-compatible since 2.0)
       */
      public static <E> ImmutableMultiset<E> of(E element) {
        return copyFromElements(element);
      }
    
      /**
       * Returns an immutable multiset containing the given elements, in order.
       *
       * @throws NullPointerException if any element is null
       * @since 6.0 (source-compatible since 2.0)
       */
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 20.7K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/collect/ForwardingSortedMapImplementsMapTest.java

        } catch (RuntimeException tolerated) {
          // GWT's TreeMap.entrySet().removeAll(null) doesn't throws NPE.
        }
      }
    
      @Override
      public void testEntrySetRetainAllNullFromEmpty() {
        try {
          super.testEntrySetRetainAllNullFromEmpty();
        } catch (RuntimeException tolerated) {
          // GWT's TreeMap.entrySet().retainAll(null) doesn't throws NPE.
        }
      }
    
      @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 4.2K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/base/OptionalTest.java

      }
    
      public void testOf_null() {
        try {
          Optional.of(null);
          fail();
        } catch (NullPointerException expected) {
        }
      }
    
      public void testFromNullable() {
        Optional<String> optionalName = Optional.fromNullable("bob");
        assertEquals("bob", optionalName.get());
      }
    
      public void testFromNullable_null() {
        // not promised by spec, but easier to test
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Feb 21 18:32:41 GMT 2024
    - 11.2K bytes
    - Viewed (0)
  6. guava/src/com/google/common/collect/JdkBackedImmutableMap.java

          if (oldValue != null) {
            if (throwIfDuplicateKeys) {
              throw conflictException("key", entryArray[i], entryArray[i].getKey() + "=" + oldValue);
            }
            if (duplicates == null) {
              duplicates = new HashMap<>();
            }
            duplicates.put(key, value);
            dupCount++;
          }
        }
        if (duplicates != null) {
          @SuppressWarnings({"rawtypes", "unchecked"})
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Nov 30 21:54:06 GMT 2023
    - 4.8K bytes
    - Viewed (0)
  7. guava-testlib/src/com/google/common/collect/testing/google/AbstractMultimapTester.java

       */
      protected Entry<K, V>[] createArrayWithNullValue() {
        Entry<K, V>[] array = createSamplesArray();
        int nullValueLocation = getNullLocation();
        Entry<K, V> oldEntry = array[nullValueLocation];
        array[nullValueLocation] = Helpers.mapEntry(oldEntry.getKey(), null);
        return array;
      }
    
      /**
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 6K bytes
    - Viewed (0)
  8. guava-testlib/src/com/google/common/collect/testing/AbstractCollectionTester.java

       * Equivalent to {@link #expectMissing(Object[]) expectMissing}{@code (null)} except that the call
       * to {@code contains(null)} is permitted to throw a {@code NullPointerException}.
       *
       * @param message message to use upon assertion failure
       */
      protected void expectNullMissingWhenNullUnsupported(String message) {
        try {
          assertFalse(message, actualContents().contains(null));
        } catch (NullPointerException tolerated) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 2.6K bytes
    - Viewed (0)
  9. guava-testlib/src/com/google/common/collect/testing/AbstractIteratorTester.java

      private <T extends Iterator<E>> void internalExecuteAndCompare(
          T reference, T target, IteratorOperation method) {
        Object referenceReturnValue = null;
        PermittedMetaException referenceException = null;
        Object targetReturnValue = null;
        Exception targetException = null;
    
        try {
          targetReturnValue = method.execute(target);
        } catch (Exception e) { // sneaky checked exception
          targetException = e;
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 21.3K bytes
    - Viewed (0)
  10. guava/src/com/google/common/collect/DiscreteDomain.java

        @Override
        @CheckForNull
        public Integer next(Integer value) {
          int i = value;
          return (i == Integer.MAX_VALUE) ? null : i + 1;
        }
    
        @Override
        @CheckForNull
        public Integer previous(Integer value) {
          int i = value;
          return (i == Integer.MIN_VALUE) ? null : i - 1;
        }
    
        @Override
        Integer offset(Integer origin, long distance) {
          checkNonnegative(distance, "distance");
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 10.3K bytes
    - Viewed (0)
Back to top