Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 10 of 445 for BiIterator (0.27 seconds)

  1. guava/src/com/google/common/collect/HashBiMap.java

        return size;
      }
    
      private abstract static class BiIterator<
              K extends @Nullable Object, V extends @Nullable Object, T extends @Nullable Object>
          implements Iterator<T> {
        final HashBiMap<K, V> biMap;
    
        @Nullable Node<K, V> next;
        @Nullable Node<K, V> toRemove;
        int expectedModCount;
        int remaining;
    
        BiIterator(HashBiMap<K, V> biMap) {
          this.biMap = biMap;
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Fri Dec 26 20:08:09 GMT 2025
    - 25.7K bytes
    - Click Count (0)
  2. android/guava-tests/test/com/google/common/collect/IteratorsTest.java

      }
    
      public void testSize1() {
        Iterator<Integer> iterator = singleton(0).iterator();
        assertEquals(1, Iterators.size(iterator));
      }
    
      public void testSize_partiallyConsumed() {
        Iterator<Integer> iterator = asList(1, 2, 3, 4, 5).iterator();
        iterator.next();
        iterator.next();
        assertEquals(3, Iterators.size(iterator));
      }
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Fri Mar 13 13:01:07 GMT 2026
    - 57.3K bytes
    - Click Count (0)
  3. android/guava/src/com/google/common/collect/Iterators.java

          UnmodifiableIterator<T> iterator) {
        return checkNotNull(iterator);
      }
    
      /**
       * Returns the number of elements remaining in {@code iterator}. The iterator will be left
       * exhausted: its {@code hasNext()} method will return {@code false}.
       */
      public static int size(Iterator<?> iterator) {
        long count = 0L;
        while (iterator.hasNext()) {
          iterator.next();
          count++;
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Sep 16 12:42:11 GMT 2025
    - 51.4K bytes
    - Click Count (0)
  4. guava/src/com/google/common/collect/Iterators.java

          UnmodifiableIterator<T> iterator) {
        return checkNotNull(iterator);
      }
    
      /**
       * Returns the number of elements remaining in {@code iterator}. The iterator will be left
       * exhausted: its {@code hasNext()} method will return {@code false}.
       */
      public static int size(Iterator<?> iterator) {
        long count = 0L;
        while (iterator.hasNext()) {
          iterator.next();
          count++;
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Sep 16 12:42:11 GMT 2025
    - 51.4K bytes
    - Click Count (0)
  5. guava-testlib/test/com/google/common/collect/testing/IteratorTesterTest.java

       */
      static class IteratorWithJdkBug6529795<T> implements Iterator<T> {
        Iterator<T> iterator;
        boolean nextThrewException;
    
        IteratorWithJdkBug6529795(Iterator<T> iterator) {
          this.iterator = iterator;
        }
    
        @Override
        public boolean hasNext() {
          return iterator.hasNext();
        }
    
        @Override
        public T next() {
          try {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Wed Aug 06 18:32:41 GMT 2025
    - 10.3K bytes
    - Click Count (0)
  6. android/guava/src/com/google/common/collect/ForwardingCollection.java

        Iterator<E> iterator = iterator();
        while (iterator.hasNext()) {
          if (Objects.equals(iterator.next(), object)) {
            iterator.remove();
            return true;
          }
        }
        return false;
      }
    
      /**
       * A sensible definition of {@link #removeAll} in terms of {@link #iterator}, using the iterator's
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Jul 08 18:32:10 GMT 2025
    - 8.1K bytes
    - Click Count (0)
  7. guava/src/com/google/common/collect/ForwardingCollection.java

        Iterator<E> iterator = iterator();
        while (iterator.hasNext()) {
          if (Objects.equals(iterator.next(), object)) {
            iterator.remove();
            return true;
          }
        }
        return false;
      }
    
      /**
       * A sensible definition of {@link #removeAll} in terms of {@link #iterator}, using the iterator's
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Jul 08 18:32:10 GMT 2025
    - 8.1K bytes
    - Click Count (0)
  8. android/guava/src/com/google/common/collect/StandardTable.java

        Map<R, V> output = new LinkedHashMap<>();
        Iterator<Entry<R, Map<C, V>>> iterator = backingMap.entrySet().iterator();
        while (iterator.hasNext()) {
          Entry<R, Map<C, V>> entry = iterator.next();
          V value = entry.getValue().remove(column);
          if (value != null) {
            output.put(entry.getKey(), value);
            if (entry.getValue().isEmpty()) {
              iterator.remove();
            }
          }
        }
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Sep 22 18:35:44 GMT 2025
    - 29.4K bytes
    - Click Count (0)
  9. guava-testlib/src/com/google/common/collect/testing/testers/CollectionIteratorTester.java

          @Override
          protected Iterator<E> newTargetIterator() {
            resetCollection();
            return collection.iterator();
          }
    
          @Override
          protected void verify(List<E> elements) {
            expectContents(elements);
          }
        }.test();
      }
    
      public void testIteratorNoSuchElementException() {
        Iterator<E> iterator = collection.iterator();
        while (iterator.hasNext()) {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Aug 07 16:05:33 GMT 2025
    - 6.1K bytes
    - Click Count (0)
  10. android/guava-testlib/src/com/google/common/collect/testing/IteratorTester.java

    import java.util.Collections;
    import java.util.Iterator;
    import org.jspecify.annotations.NullMarked;
    import org.jspecify.annotations.Nullable;
    
    /**
     * A utility for testing an Iterator implementation by comparing its behavior to that of a "known
     * good" reference implementation. In order to accomplish this, it's important to test a great
     * variety of sequences of the {@link Iterator#next}, {@link Iterator#hasNext} and {@link
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Feb 23 19:19:10 GMT 2026
    - 4.3K bytes
    - Click Count (0)
Back to Top