Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 17 for Remove (0.7 sec)

  1. guava-tests/test/com/google/common/collect/IteratorsTest.java

        assertTrue(cycle.hasNext());
        try {
          cycle.remove();
          fail("no exception thrown");
        } catch (IllegalStateException expected) {
        }
      }
    
      public void testCycleRemoveSameElementTwice() {
        Iterator<String> cycle = Iterators.cycle("a", "b");
        cycle.next();
        cycle.remove();
        try {
          cycle.remove();
          fail("no exception thrown");
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 55.7K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/collect/SetsTest.java

                        int size = elements.length;
                        // Remove last element, if size > 1
                        Set<String> set1 =
                            (size > 1)
                                ? Sets.newHashSet(Arrays.asList(elements).subList(0, size - 1))
                                : Sets.newHashSet(elements);
                        // Remove first element, if size > 0
                        Set<String> set2 =
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 49.3K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/collect/Synchronized.java

        }
    
        @Override
        public Iterator<E> iterator() {
          return delegate().iterator(); // manually synchronized
        }
    
        @Override
        public boolean remove(@CheckForNull Object o) {
          synchronized (mutex) {
            return delegate().remove(o);
          }
        }
    
        @Override
        public boolean removeAll(Collection<?> c) {
          synchronized (mutex) {
            return delegate().removeAll(c);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 53.4K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/ImmutableSortedMap.java

       */
      @SuppressWarnings({"AndroidJdkLibsChecker", "Java7ApiChecker"})
      @IgnoreJRERequirement // Users will use this only if they're already using streams.
      @Beta // TODO: b/288085449 - Remove.
      public static <T extends @Nullable Object, K, V>
          Collector<T, ?, ImmutableSortedMap<K, V>> toImmutableSortedMap(
              Comparator<? super K> comparator,
              Function<? super T, ? extends K> keyFunction,
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 53.2K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/Iterators.java

          }
    
          @Override
          public void remove() {
            iterator.remove();
          }
        };
      }
    
      /**
       * Returns an iterator that cycles indefinitely over the provided elements.
       *
       * <p>The returned iterator supports {@code remove()}. After {@code remove()} is called,
       * subsequent cycles omit the removed element, but {@code elements} does not change. The
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Tue Jan 30 00:14:39 GMT 2024
    - 50.5K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/Multimaps.java

                   */
                  return uncheckedCastNullableTToT(map.get(key));
                }
    
                @Override
                public void remove() {
                  checkRemove(i == 1);
                  i = -1;
                  map.remove(key);
                }
              };
            }
    
            @Override
            public int size() {
              return map.containsKey(key) ? 1 : 0;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 86.4K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/MapMakerInternalMap.java

        }
      }
    
      @CheckForNull
      @CanIgnoreReturnValue
      @Override
      public V remove(@CheckForNull Object key) {
        if (key == null) {
          return null;
        }
        int hash = hash(key);
        return segmentFor(hash).remove(key, hash);
      }
    
      @CanIgnoreReturnValue
      @Override
      public boolean remove(@CheckForNull Object key, @CheckForNull Object value) {
        if (key == null || value == null) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 91.9K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/collect/IteratorsTest.java

        assertTrue(cycle.hasNext());
        try {
          cycle.remove();
          fail("no exception thrown");
        } catch (IllegalStateException expected) {
        }
      }
    
      public void testCycleRemoveSameElementTwice() {
        Iterator<String> cycle = Iterators.cycle("a", "b");
        cycle.next();
        cycle.remove();
        try {
          cycle.remove();
          fail("no exception thrown");
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Apr 30 18:43:01 GMT 2024
    - 56.5K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/collect/MapsTest.java

          iterator.next();
          iterator.remove();
          fail("UnsupportedOperationException expected");
        } catch (UnsupportedOperationException expected) {
        }
    
        Set<Entry<Integer, String>> entries = unmod.entrySet();
        try {
          Iterator<Entry<Integer, String>> iterator = entries.iterator();
          iterator.next();
          iterator.remove();
          fail("UnsupportedOperationException expected");
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Mar 04 16:06:01 GMT 2024
    - 67.2K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/collect/MapsTest.java

          iterator.next();
          iterator.remove();
          fail("UnsupportedOperationException expected");
        } catch (UnsupportedOperationException expected) {
        }
    
        Set<Entry<Integer, String>> entries = unmod.entrySet();
        try {
          Iterator<Entry<Integer, String>> iterator = entries.iterator();
          iterator.next();
          iterator.remove();
          fail("UnsupportedOperationException expected");
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Mar 04 16:06:01 GMT 2024
    - 64.3K bytes
    - Viewed (0)
Back to top