Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 30 for setValue2 (0.12 sec)

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

      @CollectionSize.Require(absent = ZERO)
      public void testSetValue() {
        for (Entry<K, V> entry : getMap().entrySet()) {
          if (entry.getKey().equals(k0())) {
            assertEquals("entry.setValue() should return the old value", v0(), entry.setValue(v3()));
            break;
          }
        }
        expectReplacement(entry(k0(), v3()));
      }
    
      @MapFeature.Require({SUPPORTS_PUT, ALLOWS_NULL_VALUES})
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  2. android/guava-testlib/src/com/google/common/collect/testing/testers/MapEntrySetTester.java

      @CollectionSize.Require(absent = ZERO)
      public void testSetValue() {
        for (Entry<K, V> entry : getMap().entrySet()) {
          if (entry.getKey().equals(k0())) {
            assertEquals("entry.setValue() should return the old value", v0(), entry.setValue(v3()));
            break;
          }
        }
        expectReplacement(entry(k0(), v3()));
      }
    
      @MapFeature.Require({SUPPORTS_PUT, ALLOWS_NULL_VALUES})
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  3. guava/src/com/google/common/util/concurrent/AbstractTransformFuture.java

        } finally {
          function = null;
        }
    
        /*
         * If set()/setValue() throws an Error, we let it propagate. Why? The most likely Error is a
         * StackOverflowError (from deep transform(..., directExecutor()) nesting), and calling
         * setException(stackOverflowError) would fail:
         *
         * - If the stack overflowed before set()/setValue() could even store the result in the output
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 25 13:13:32 UTC 2024
    - 11K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/ArrayTable.java

            public V getValue() {
              return ArrayMap.this.getValue(index);
            }
    
            @Override
            @ParametricNullness
            public V setValue(@ParametricNullness V value) {
              return ArrayMap.this.setValue(index, value);
            }
          };
        }
    
        @Override
        Iterator<Entry<K, V>> entryIterator() {
          return new AbstractIndexedListIterator<Entry<K, V>>(size()) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 26.3K bytes
    - Viewed (0)
  5. android/guava-testlib/src/com/google/common/collect/testing/MapInterfaceTest.java

          // Expected.
        }
        assertInvariants(map);
      }
    
      public void testEntrySetSetValue() {
        // TODO: Investigate the extent to which, in practice, maps that support
        // put() also support Entry.setValue().
        if (!supportsPut) {
          return;
        }
    
        Map<K, V> map;
        V valueToSet;
        try {
          map = makePopulatedMap();
          valueToSet = getValueNotInPopulatedMap();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 43.8K bytes
    - Viewed (0)
  6. android/guava-testlib/src/com/google/common/collect/testing/google/UnmodifiableCollectionTests.java

          @SuppressWarnings("unchecked")
          Entry<?, @Nullable Object> nullableValueEntry = (Entry<?, @Nullable Object>) entry;
          nullableValueEntry.setValue(null);
          fail("setValue on unmodifiable Map.Entry succeeded");
        } catch (UnsupportedOperationException expected) {
        }
      }
    
      /**
       * Verifies that an Iterator is unmodifiable.
       *
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 14.6K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/AbstractSortedSetMultimap.java

       * Returns a map view that associates each key with the corresponding values in the multimap.
       * Changes to the returned map, such as element removal, will update the underlying multimap. The
       * map does not support {@code setValue} on its entries, {@code put}, or {@code putAll}.
       *
       * <p>When passed a key that is present in the map, {@code asMap().get(Object)} has the same
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 5.5K bytes
    - Viewed (0)
  8. compat/maven-compat/src/main/java/org/apache/maven/profiles/ProfilesConversionUtils.java

                if (profileProp != null) {
                    ActivationProperty prop = new ActivationProperty();
    
                    prop.setName(profileProp.getName());
                    prop.setValue(profileProp.getValue());
    
                    activation.setProperty(prop);
                }
    
                ActivationOS profileOs = profileActivation.getOs();
    
                if (profileOs != null) {
    Registered: Sun Nov 03 03:35:11 UTC 2024
    - Last Modified: Fri Oct 25 12:31:46 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/collect/testing/Helpers.java

            return value;
          }
    
          @Override
          public V setValue(V value) {
            throw new UnsupportedOperationException();
          }
    
          @SuppressWarnings("unchecked")
          @Override
          public boolean equals(@Nullable Object o) {
            if (o instanceof Entry) {
              Entry<K, V> e = (Entry<K, V>) o;
              e.setValue(value); // muhahaha!
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 17.5K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/collect/MultimapsTest.java

        assertThrows(UnsupportedOperationException.class, () -> fromIterator.setValue(2));
        Entry<String, Integer> fromToArray = (Entry<String, Integer>) unmod.entries().toArray()[0];
        assertThrows(UnsupportedOperationException.class, () -> fromToArray.setValue(2));
        Entry<String, Integer>[] array = (Entry<String, Integer>[]) new Entry<?, ?>[2];
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 38.4K bytes
    - Viewed (0)
Back to top