Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 22 for Consumer (0.25 sec)

  1. guava-testlib/src/com/google/common/collect/testing/SpliteratorTester.java

              GeneralSpliterator<E> spliterator, Consumer<? super E> consumer) {
            spliterator.forEachRemaining(consumer);
          }
        },
        NO_SPLIT_TRY_ADVANCE {
          @Override
          <E extends @Nullable Object> void forEach(
              GeneralSpliterator<E> spliterator, Consumer<? super E> consumer) {
            while (spliterator.tryAdvance(consumer)) {
              // do nothing
            }
          }
        },
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 18:19:31 GMT 2024
    - 11.9K bytes
    - Viewed (0)
  2. guava/src/com/google/common/collect/ImmutableList.java

          protected E get(int index) {
            return ImmutableList.this.get(index);
          }
        };
      }
    
      @Override
      public void forEach(Consumer<? super E> consumer) {
        checkNotNull(consumer);
        int n = size();
        for (int i = 0; i < n; i++) {
          consumer.accept(get(i));
        }
      }
    
      @Override
      public int indexOf(@CheckForNull Object object) {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 30K bytes
    - Viewed (1)
  3. guava/src/com/google/common/collect/ImmutableEnumSet.java

    import java.io.InvalidObjectException;
    import java.io.ObjectInputStream;
    import java.io.Serializable;
    import java.util.Collection;
    import java.util.EnumSet;
    import java.util.Spliterator;
    import java.util.function.Consumer;
    import javax.annotation.CheckForNull;
    
    /**
     * Implementation of {@link ImmutableSet} backed by a non-empty {@link java.util.EnumSet}.
     *
     * @author Jared Levy
     */
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 4.5K bytes
    - Viewed (0)
  4. guava/src/com/google/common/collect/CollectSpliterators.java

            this.delegate = delegate;
          }
    
          @Override
          public boolean tryAdvance(Consumer<? super T> action) {
            return delegate.tryAdvance((IntConsumer) i -> action.accept(function.apply(i)));
          }
    
          @Override
          public void forEachRemaining(Consumer<? super T> action) {
            delegate.forEachRemaining((IntConsumer) i -> action.accept(function.apply(i)));
          }
    
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Feb 19 15:21:23 GMT 2024
    - 19.8K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/Collections2.java

    import java.util.Arrays;
    import java.util.Collection;
    import java.util.Collections;
    import java.util.Comparator;
    import java.util.Iterator;
    import java.util.List;
    import java.util.Spliterator;
    import java.util.function.Consumer;
    import javax.annotation.CheckForNull;
    import org.checkerframework.checker.nullness.qual.Nullable;
    
    /**
     * Provides static methods for working with {@code Collection} instances.
     *
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 23.1K bytes
    - Viewed (0)
  6. guava/src/com/google/common/collect/ImmutableSet.java

          return CollectSpliterators.indexed(size(), SPLITERATOR_CHARACTERISTICS, this::get);
        }
    
        @Override
        public void forEach(Consumer<? super E> consumer) {
          checkNotNull(consumer);
          int n = size();
          for (int i = 0; i < n; i++) {
            consumer.accept(get(i));
          }
        }
    
        @Override
        int copyIntoArray(@Nullable Object[] dst, int offset) {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 35.4K bytes
    - Viewed (0)
  7. guava/src/com/google/common/collect/ImmutableSortedSet.java

    import java.util.Comparator;
    import java.util.Iterator;
    import java.util.NavigableSet;
    import java.util.SortedSet;
    import java.util.Spliterator;
    import java.util.Spliterators;
    import java.util.function.Consumer;
    import java.util.stream.Collector;
    import javax.annotation.CheckForNull;
    import org.checkerframework.checker.nullness.qual.Nullable;
    
    /**
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 38.5K bytes
    - Viewed (0)
  8. guava/src/com/google/common/collect/ImmutableSortedMap.java

    import java.util.NavigableMap;
    import java.util.SortedMap;
    import java.util.Spliterator;
    import java.util.TreeMap;
    import java.util.function.BiConsumer;
    import java.util.function.BinaryOperator;
    import java.util.function.Consumer;
    import java.util.function.Function;
    import java.util.stream.Collector;
    import java.util.stream.Collectors;
    import javax.annotation.CheckForNull;
    import org.checkerframework.checker.nullness.qual.Nullable;
    
    /**
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 50.3K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/util/concurrent/ClosingFuture.java

       *
       * @param consumer a callback whose method will be called (using {@code executor}) when this
       *     operation is done
       */
      public void finishToValueAndCloser(
          final ValueAndCloserConsumer<? super V> consumer, Executor executor) {
        checkNotNull(consumer);
        if (!compareAndUpdateState(OPEN, WILL_CREATE_VALUE_AND_CLOSER)) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 98.5K bytes
    - Viewed (0)
  10. guava/src/com/google/common/collect/Cut.java

        return false;
      }
    
      // Prevent "missing hashCode" warning by explicitly forcing subclasses implement it
      @Override
      public abstract int hashCode();
    
      /*
       * The implementation neither produces nor consumes any non-null instance of type C, so
       * casting the type parameter is safe.
       */
      @SuppressWarnings("unchecked")
      static <C extends Comparable> Cut<C> belowAll() {
        return (Cut<C>) BelowAll.INSTANCE;
      }
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 12.3K bytes
    - Viewed (0)
Back to top