- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 580 for removeIf (0.05 sec)
-
android/guava-tests/test/com/google/common/collect/IterablesTest.java
assertTrue( removeIf( list, new Predicate<String>() { @Override public boolean apply(String s) { return s.equals("b") || s.equals("d") || s.equals("f"); } })); assertEquals(newArrayList("a", "c", "e"), list); assertFalse( removeIf( list,
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 19:12:33 UTC 2024 - 45K bytes - Viewed (0) -
guava/src/com/google/common/collect/Collections2.java
} @Override public boolean remove(@CheckForNull Object element) { return contains(element) && unfiltered.remove(element); } @Override public boolean removeAll(final Collection<?> collection) { return removeIf(collection::contains); } @Override public boolean retainAll(final Collection<?> collection) { return removeIf(element -> !collection.contains(element)); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 20:24:49 UTC 2024 - 23.1K bytes - Viewed (0) -
guava/src/com/google/common/collect/Lists.java
return fromList.isEmpty(); } @Override public boolean removeIf(Predicate<? super T> filter) { checkNotNull(filter); return fromList.removeIf(element -> filter.test(function.apply(element))); } @Override @ParametricNullness public T remove(int index) { return function.apply(fromList.remove(index)); } @Override public int size() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 43.1K bytes - Viewed (0) -
guava-testlib/test/com/google/common/collect/testing/MapTestSuiteBuilderTests.java
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Apr 19 19:24:36 UTC 2023 - 11.9K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/Iterables.java
* removeFrom.removeIf(predicate)} instead. * * @param removeFrom the iterable to (potentially) remove elements from * @param predicate a predicate that determines whether an element should be removed * @return {@code true} if any elements were removed from the iterable * @throws UnsupportedOperationException if the iterable does not support {@code remove()}. * @since 2.0 */
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Apr 24 19:38:27 UTC 2024 - 42.8K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/google/UnmodifiableCollectionTests.java
try { multiset.remove(sampleElement, 2); fail("remove(Object, int) succeeded on unmodifiable collection"); } catch (UnsupportedOperationException expected) { } assertCollectionsAreEquivalent(multiset, copy); try { multiset.removeIf(x -> false); fail("removeIf(Predicate) succeeded on unmodifiable collection");
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 14.8K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/AtomicLongMap.java
* otherwise, this method returns false. */ boolean remove(K key, long value) { return map.remove(key, value); } /** * Atomically remove {@code key} from the map iff its associated value is 0. * * @since 20.0 */ @CanIgnoreReturnValue public boolean removeIfZero(K key) { return remove(key, 0); } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Apr 01 16:15:01 UTC 2024 - 11.8K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/FluentIterableTest.java
FluentIterable<Integer> cycle = fluent(1, 2).cycle(); Iterator<Integer> iterator = cycle.iterator(); iterator.next(); iterator.remove(); iterator.next(); iterator.remove(); assertFalse(iterator.hasNext()); assertFalse(cycle.iterator().hasNext()); } public void testAppend() { FluentIterable<Integer> result =
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 30.4K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/Collections2.java
} } /** * Delegates to {@link Collection#remove}. Returns {@code false} if the {@code remove} method * throws a {@code ClassCastException} or {@code NullPointerException}. */ static boolean safeRemove(Collection<?> collection, @CheckForNull Object object) { checkNotNull(collection); try { return collection.remove(object); } catch (ClassCastException | NullPointerException e) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 20:24:49 UTC 2024 - 22.8K bytes - Viewed (0) -
guava/src/com/google/common/collect/ImmutableCollection.java
* @deprecated Unsupported operation. */ @CanIgnoreReturnValue @Deprecated @Override @DoNotCall("Always throws UnsupportedOperationException") public final boolean removeIf(Predicate<? super E> filter) { throw new UnsupportedOperationException(); } /** * Guaranteed to throw an exception and leave the collection unmodified. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Aug 12 16:59:15 UTC 2024 - 18.8K bytes - Viewed (0)