Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 163 for previous (0.39 sec)

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

          protected @Nullable Integer computeNext(Integer previous) {
            return (previous == last) ? null : previous * 2;
          }
        };
      }
    
      private static class EmptyAbstractSequentialIterator<T> extends AbstractSequentialIterator<T> {
    
        public EmptyAbstractSequentialIterator() {
          super(null);
        }
    
        @Override
        protected T computeNext(T previous) {
          throw new AssertionFailedError();
        }
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Feb 26 17:19:08 GMT 2024
    - 4.7K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/collect/AbstractSequentialIterator.java

     * whose next element can always be derived from the previous element. Null elements are not
     * supported, nor is the {@link #remove()} method.
     *
     * <p>Example:
     *
     * <pre>{@code
     * Iterator<Integer> powersOfTwo =
     *     new AbstractSequentialIterator<Integer>(1) {
     *       protected Integer computeNext(Integer previous) {
     *         return (previous == 1 << 30) ? null : previous * 2;
     *       }
     *     };
     * }</pre>
     *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Jul 09 17:31:04 GMT 2021
    - 2.4K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/collect/Cut.java

          switch (boundType) {
            case CLOSED:
              return this;
            case OPEN:
              C previous = domain.previous(endpoint);
              return (previous == null) ? Cut.<C>belowAll() : new AboveValue<C>(previous);
            default:
              throw new AssertionError();
          }
        }
    
        @Override
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/util/concurrent/AbstractService.java

        monitor.enter();
        try {
          State previous = state();
          switch (previous) {
            case NEW:
            case TERMINATED:
              throw new IllegalStateException("Failed while in state:" + previous, cause);
            case RUNNING:
            case STARTING:
            case STOPPING:
              snapshot = new StateSnapshot(FAILED, false, cause);
              enqueueFailedEvent(previous, cause);
              break;
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 18:32:03 GMT 2023
    - 20.4K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/AtomicDoubleTest.java

          prev = x;
        }
      }
    
      /** getAndSet returns previous value and sets to given value */
      public void testGetAndSet() {
        double prev = Math.E;
        AtomicDouble at = new AtomicDouble(prev);
        for (double x : VALUES) {
          assertBitEquals(prev, at.getAndSet(x));
          prev = x;
        }
      }
    
      /** getAndAdd returns previous value and adds given value */
      public void testGetAndAdd() {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Feb 09 22:57:07 GMT 2022
    - 10.2K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/RegularContiguousSet.java

          final C first = first();
    
          @Override
          @CheckForNull
          protected C computeNext(C previous) {
            return equalsOrThrow(previous, first) ? null : domain.previous(previous);
          }
        };
      }
    
      private static boolean equalsOrThrow(Comparable<?> left, @CheckForNull Comparable<?> right) {
        return right != null && Range.compareOrThrow(left, right) == 0;
      }
    
      @Override
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 8.4K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/ExecutionSequencer.java

    /**
     * Serializes execution of tasks, somewhat like an "asynchronous {@code synchronized} block." Each
     * {@linkplain #submit enqueued} callable will not be submitted to its associated executor until the
     * previous callable has returned -- and, if the previous callable was an {@link AsyncCallable}, not
     * until the {@code Future} it returned is {@linkplain Future#isDone done} (successful, failed, or
     * cancelled).
     *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 01 21:46:34 GMT 2024
    - 22.1K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/collect/TransformedListIterator.java

      }
    
      @Override
      public final boolean hasPrevious() {
        return backingIterator().hasPrevious();
      }
    
      @Override
      @ParametricNullness
      public final T previous() {
        return transform(backingIterator().previous());
      }
    
      @Override
      public final int nextIndex() {
        return backingIterator().nextIndex();
      }
    
      @Override
      public final int previousIndex() {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Nov 21 21:43:01 GMT 2023
    - 2.1K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/collect/DiscreteDomainTest.java

        @Override
        public Integer next(Integer value) {
          return DELEGATE.next(value);
        }
    
        @Override
        public Integer previous(Integer value) {
          return DELEGATE.previous(value);
        }
    
        // Do *not* override offset() to delegate: We want to test the default implementation.
    
        @Override
        public long distance(Integer start, Integer end) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 3.6K bytes
    - Viewed (0)
  10. guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ForwardingImmutableMap.java

        Map<K, V> delegate = Maps.newLinkedHashMap();
        for (Entry<? extends K, ? extends V> entry : entries) {
          K key = checkNotNull(entry.getKey());
          V previous = delegate.put(key, checkNotNull(entry.getValue()));
          if (throwIfDuplicateKeys && previous != null) {
            throw new IllegalArgumentException("duplicate key: " + key);
          }
        }
        this.delegate = Collections.unmodifiableMap(delegate);
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Jan 24 16:03:45 GMT 2024
    - 3.9K bytes
    - Viewed (0)
Back to top