Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 408 for Present (0.19 sec)

  1. guava/src/com/google/common/base/Present.java

        return new Present<>(
            checkNotNull(
                function.apply(reference),
                "the Function passed to Optional.transform() must not return null."));
      }
    
      @Override
      public boolean equals(@CheckForNull Object object) {
        if (object instanceof Present) {
          Present<?> other = (Present<?>) object;
          return reference.equals(other.reference);
        }
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Fri Oct 01 17:18:04 GMT 2021
    - 2.4K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/base/Present.java

        return new Present<>(
            checkNotNull(
                function.apply(reference),
                "the Function passed to Optional.transform() must not return null."));
      }
    
      @Override
      public boolean equals(@CheckForNull Object object) {
        if (object instanceof Present) {
          Present<?> other = (Present<?>) object;
          return reference.equals(other.reference);
        }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Oct 01 17:18:04 GMT 2021
    - 2.4K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/graph/MutableValueGraph.java

      /**
       * Adds {@code node} if it is not already present.
       *
       * <p><b>Nodes must be unique</b>, just as {@code Map} keys must be. They must also be non-null.
       *
       * @return {@code true} if the graph was modified as a result of this call
       */
      @CanIgnoreReturnValue
      boolean addNode(N node);
    
      /**
       * Adds an edge connecting {@code nodeU} to {@code nodeV} if one is not already present, and sets
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 26 17:43:39 GMT 2021
    - 4.4K bytes
    - Viewed (0)
  4. guava-testlib/src/com/google/common/collect/testing/testers/CollectionRemoveTester.java

      @CollectionFeature.Require(SUPPORTS_REMOVE)
      @CollectionSize.Require(absent = ZERO)
      public void testRemove_present() {
        int initialSize = collection.size();
        assertTrue("remove(present) should return true", collection.remove(e0()));
        assertEquals(
            "remove(present) should decrease a collection's size by one.",
            initialSize - 1,
            collection.size());
        expectMissing(e0());
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/collect/SortedListsTest.java

        switch (presentBehavior) {
          case FIRST_PRESENT:
            if (list.contains(key)) {
              assertEquals(list.indexOf(key), answer);
              return;
            }
            break;
          case LAST_PRESENT:
            if (list.contains(key)) {
              assertEquals(list.lastIndexOf(key), answer);
              return;
            }
            break;
          case ANY_PRESENT:
            if (list.contains(key)) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Feb 19 20:34:55 GMT 2024
    - 4.1K bytes
    - Viewed (0)
  6. android/guava-testlib/src/com/google/common/collect/testing/testers/MapPutTester.java

      }
    
      @MapFeature.Require(absent = SUPPORTS_PUT)
      @CollectionSize.Require(absent = ZERO)
      public void testPut_unsupportedPresentExistingValue() {
        try {
          assertEquals("put(present, existingValue) should return present or throw", v0(), put(e0()));
        } catch (UnsupportedOperationException tolerated) {
        }
        expectUnchanged();
      }
    
      @MapFeature.Require(absent = SUPPORTS_PUT)
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 9.4K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/CollectionFuture.java

      @CheckForNull @LazyInit private List<@Nullable Present<V>> values;
    
      CollectionFuture(
          ImmutableCollection<? extends ListenableFuture<? extends V>> futures,
          boolean allMustSucceed) {
        super(futures, allMustSucceed, true);
    
        List<@Nullable Present<V>> values =
            futures.isEmpty()
                ? Collections.<@Nullable Present<V>>emptyList()
                : Lists.<@Nullable Present<V>>newArrayListWithCapacity(futures.size());
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 01 21:46:34 GMT 2024
    - 3.8K bytes
    - Viewed (0)
  8. android/guava-testlib/src/com/google/common/collect/testing/testers/CollectionRemoveTester.java

      @CollectionFeature.Require(SUPPORTS_REMOVE)
      @CollectionSize.Require(absent = ZERO)
      public void testRemove_present() {
        int initialSize = collection.size();
        assertTrue("remove(present) should return true", collection.remove(e0()));
        assertEquals(
            "remove(present) should decrease a collection's size by one.",
            initialSize - 1,
            collection.size());
        expectMissing(e0());
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/hash/BloomFilterTest.java

        // flip GOLDEN_PRESENT_KEY to true even if it wasn't explicitly inserted
        // (false positive).
        assertThat(bloomFilter.mightContain(GOLDEN_PRESENT_KEY)).isFalse();
        for (int i = 0; i < NUM_PUTS; i++) {
          bloomFilter.put(getNonGoldenRandomKey());
        }
        bloomFilter.put(GOLDEN_PRESENT_KEY);
    
        int numThreads = 12;
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Nov 09 22:49:56 GMT 2023
    - 21.3K bytes
    - Viewed (0)
  10. android/guava-testlib/src/com/google/common/collect/testing/testers/MapRemoveTester.java

      @MapFeature.Require(SUPPORTS_REMOVE)
      @CollectionSize.Require(absent = ZERO)
      public void testRemove_present() {
        int initialSize = getMap().size();
        assertEquals("remove(present) should return the associated value", v0(), getMap().remove(k0()));
        assertEquals(
            "remove(present) should decrease a map's size by one.", initialSize - 1, getMap().size());
        expectMissing(e0());
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 5.9K bytes
    - Viewed (0)
Back to top