Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 69 for predicate (0.16 sec)

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

        <T extends @Nullable Object> Predicate<T> withNarrowedType() {
          return (Predicate<T>) this;
        }
      }
    
      /**
       * @see Predicates#not(Predicate)
       */
      private static final class NotPredicate<T extends @Nullable Object>
          implements Predicate<T>, Serializable {
        final Predicate<T> predicate;
    
        NotPredicate(Predicate<T> predicate) {
          this.predicate = checkNotNull(predicate);
        }
    
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 26.6K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/base/PredicatesTest.java

      }
    
      public void testAnd_listDefensivelyCopied() {
        List<Predicate<Object>> list = new ArrayList<>();
        Predicate<Object> predicate = Predicates.and(list);
        assertTrue(predicate.apply(1));
        list.add(Predicates.alwaysFalse());
        assertTrue(predicate.apply(1));
      }
    
      public void testAnd_iterableDefensivelyCopied() {
        List<Predicate<Object>> list = new ArrayList<>();
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Oct 28 16:03:47 UTC 2025
    - 32.3K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/collect/IterablesTest.java

        List<String> list = new ArrayList<>();
        Predicate<String> predicate = equalTo("pants");
    
        assertFalse(any(list, predicate));
        list.add("cool");
        assertFalse(any(list, predicate));
        list.add("pants");
        assertTrue(any(list, predicate));
      }
    
      public void testAll() {
        List<String> list = new ArrayList<>();
        Predicate<String> predicate = equalTo("cool");
    
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Oct 28 18:44:53 UTC 2025
    - 45.6K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/base/PredicatesTest.java

      }
    
      public void testAnd_listDefensivelyCopied() {
        List<Predicate<Object>> list = new ArrayList<>();
        Predicate<Object> predicate = Predicates.and(list);
        assertTrue(predicate.apply(1));
        list.add(Predicates.alwaysFalse());
        assertTrue(predicate.apply(1));
      }
    
      public void testAnd_iterableDefensivelyCopied() {
        List<Predicate<Object>> list = new ArrayList<>();
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Oct 28 16:03:47 UTC 2025
    - 32.3K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/collect/Collections2.java

        final Collection<E> unfiltered;
        final Predicate<? super E> predicate;
    
        FilteredCollection(Collection<E> unfiltered, Predicate<? super E> predicate) {
          this.unfiltered = unfiltered;
          this.predicate = predicate;
        }
    
        FilteredCollection<E> createCombined(Predicate<? super E> newPredicate) {
          return new FilteredCollection<>(unfiltered, Predicates.and(predicate, newPredicate));
        }
    
        @Override
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Sat Aug 09 01:14:59 UTC 2025
    - 22.6K bytes
    - Viewed (0)
  6. guava/src/com/google/common/collect/Iterables.java

          return ((Collection<T>) removeFrom).removeIf(predicate);
        }
        return Iterators.removeIf(removeFrom.iterator(), predicate);
      }
    
      /** Removes and returns the first matching element, or returns {@code null} if there is none. */
      static <T extends @Nullable Object> @Nullable T removeFirstMatching(
          Iterable<T> removeFrom, Predicate<? super T> predicate) {
        checkNotNull(predicate);
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Nov 17 22:50:48 UTC 2025
    - 43.6K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/Iterables.java

          Iterable<T> iterable, Predicate<? super T> predicate) {
        return Iterators.find(iterable.iterator(), predicate);
      }
    
      /**
       * Returns the first element in {@code iterable} that satisfies the given predicate, or {@code
       * defaultValue} if none found. Note that this can usually be handled more naturally using {@code
       * tryFind(iterable, predicate).or(defaultValue)}.
       *
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Sep 16 18:35:28 UTC 2025
    - 43.8K bytes
    - Viewed (0)
  8. guava-testlib/src/com/google/common/testing/GcFinalization.java

      }
    
      /**
       * Waits until the given predicate returns true, invoking the garbage collector as necessary to
       * try to ensure that this will happen.
       *
       * @throws RuntimeException if timed out or interrupted while waiting
       */
      @SuppressWarnings("removal") // b/260137033
      public static void awaitDone(FinalizationPredicate predicate) {
        if (predicate.isDone()) {
          return;
        }
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Mar 17 20:26:29 UTC 2025
    - 11.5K bytes
    - Viewed (0)
  9. guava/src/com/google/common/collect/Multisets.java

      }
    
      private static final class FilteredMultiset<E extends @Nullable Object> extends ViewMultiset<E> {
        final Multiset<E> unfiltered;
        final Predicate<? super E> predicate;
    
        FilteredMultiset(Multiset<E> unfiltered, Predicate<? super E> predicate) {
          this.unfiltered = checkNotNull(unfiltered);
          this.predicate = checkNotNull(predicate);
        }
    
        @Override
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Sep 22 18:35:44 UTC 2025
    - 41.2K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/collect/Multisets.java

      }
    
      private static final class FilteredMultiset<E extends @Nullable Object> extends ViewMultiset<E> {
        final Multiset<E> unfiltered;
        final Predicate<? super E> predicate;
    
        FilteredMultiset(Multiset<E> unfiltered, Predicate<? super E> predicate) {
          this.unfiltered = checkNotNull(unfiltered);
          this.predicate = checkNotNull(predicate);
        }
    
        @Override
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Sep 22 18:35:44 UTC 2025
    - 41.3K bytes
    - Viewed (0)
Back to top