Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 651 for iterators (0.07 sec)

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

        Iterator<String> iterator = asList("a", "b", "a").iterator();
        List<String> list = ImmutableList.copyOf(iterator);
        assertEquals(asList("a", "b", "a"), list);
      }
    
      public void testCopyOf_iteratorContainingNull() {
        Iterator<@Nullable String> iterator =
            Arrays.<@Nullable String>asList("a", null, "b").iterator();
        assertThrows(
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 23.5K bytes
    - Viewed (0)
  2. guava/src/com/google/common/collect/Lists.java

            : newArrayList(elements.iterator());
      }
    
      /**
       * Creates a <i>mutable</i> {@code ArrayList} instance containing the given elements; a very thin
       * shortcut for creating an empty list and then calling {@link Iterators#addAll}.
       *
       * <p><b>Note:</b> if mutability is not required and the elements are non-null, use {@link
       * ImmutableList#copyOf(Iterator)} instead.
       */
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 43.1K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/collect/MinMaxPriorityQueue.java

          }
        }
      }
    
      /**
       * Returns an iterator over the elements contained in this collection, <i>in no particular
       * order</i>.
       *
       * <p>The iterator is <i>fail-fast</i>: If the MinMaxPriorityQueue is modified at any time after
       * the iterator is created, in any way except through the iterator's own remove method, the
       * iterator will generally throw a {@link ConcurrentModificationException}. Thus, in the face of
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 34.1K bytes
    - Viewed (0)
  4. guava/src/com/google/common/collect/TreeRangeMap.java

              @Override
              public Iterator<Entry<Range<K>, V>> iterator() {
                return entryIterator();
              }
    
              @Override
              public boolean retainAll(Collection<?> c) {
                return removeEntryIf(not(in(c)));
              }
    
              @Override
              public int size() {
                return Iterators.size(iterator());
              }
    
              @Override
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 26.7K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/MinMaxPriorityQueue.java

          }
        }
      }
    
      /**
       * Returns an iterator over the elements contained in this collection, <i>in no particular
       * order</i>.
       *
       * <p>The iterator is <i>fail-fast</i>: If the MinMaxPriorityQueue is modified at any time after
       * the iterator is created, in any way except through the iterator's own remove method, the
       * iterator will generally throw a {@link ConcurrentModificationException}. Thus, in the face of
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 34.1K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/ForwardingMap.java

      }
    
      /**
       * A sensible definition of {@link #clear} in terms of the {@code iterator} method of {@link
       * #entrySet}. In many cases, you may wish to override {@link #clear} to forward to this
       * implementation.
       *
       * @since 7.0
       */
      protected void standardClear() {
        Iterators.clear(entrySet().iterator());
      }
    
      /**
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri May 12 15:26:39 UTC 2023
    - 9.9K bytes
    - Viewed (0)
  7. guava/src/com/google/common/collect/Collections2.java

        }
    
        @Override
        public boolean isEmpty() {
          return !Iterables.any(unfiltered, predicate);
        }
    
        @Override
        public Iterator<E> iterator() {
          return Iterators.filter(unfiltered.iterator(), predicate);
        }
    
        @Override
        public Spliterator<E> spliterator() {
          return CollectSpliterators.filter(unfiltered.spliterator(), predicate);
        }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 20:24:49 UTC 2024
    - 23.1K bytes
    - Viewed (0)
  8. guava/src/com/google/common/collect/ForwardingMultiset.java

        }
    
        @Override
        public Iterator<E> iterator() {
          return Multisets.elementIterator(multiset().entrySet().iterator());
        }
      }
    
      /**
       * A sensible definition of {@link #iterator} in terms of {@link #entrySet} and {@link
       * #remove(Object)}. If you override either of these methods, you may wish to override {@link
       * #iterator} to forward to this implementation.
       *
       * @since 7.0
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri May 12 15:26:39 UTC 2023
    - 10.4K bytes
    - Viewed (0)
  9. guava/src/com/google/common/collect/ImmutableSortedSet.java

            size(), SPLITERATOR_CHARACTERISTICS | Spliterator.SIZED) {
          final UnmodifiableIterator<E> iterator = iterator();
    
          @Override
          public boolean tryAdvance(Consumer<? super E> action) {
            if (iterator.hasNext()) {
              action.accept(iterator.next());
              return true;
            } else {
              return false;
            }
          }
    
          @Override
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 39.1K bytes
    - Viewed (0)
  10. docs/contribute/concurrency.md

    #### Per-Connection Locks
    
    Each connection has its own lock. The connections in the pool are all in a `ConcurrentLinkedQueue`. Due to data races, iterators of this queue may return removed connections. Callers must check the connection's `noNewExchanges` property before using connections from the pool.
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Feb 06 16:35:36 UTC 2022
    - 7K bytes
    - Viewed (0)
Back to top