Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for Clean (0.13 sec)

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

            int newValue = Math.max(0, oldValue - occurrences);
            if (existingCounter.compareAndSet(oldValue, newValue)) {
              if (newValue == 0) {
                // Just CASed to 0; remove the entry to clean up the map. If the removal fails,
                // another thread has already replaced it with a new counter, which is fine.
                countMap.remove(element, existingCounter);
              }
              return oldValue;
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 20.9K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/collect/ConcurrentHashMultiset.java

            int newValue = Math.max(0, oldValue - occurrences);
            if (existingCounter.compareAndSet(oldValue, newValue)) {
              if (newValue == 0) {
                // Just CASed to 0; remove the entry to clean up the map. If the removal fails,
                // another thread has already replaced it with a new counter, which is fine.
                countMap.remove(element, existingCounter);
              }
              return oldValue;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 20.9K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/collect/QueuesTest.java

          assertThat(drained).isAtMost(1);
    
          assertThat(timer.elapsed(MILLISECONDS)).isAtLeast(10L);
    
          // If even the first one wasn't there, clean up so that the next test doesn't see an element.
          producerThread.cancel(true);
          producer.doneProducing.await();
          if (drained == 0) {
            q.poll(); // not necessarily there if producer was interrupted
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 12K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/collect/QueuesTest.java

          assertThat(drained).isAtMost(1);
    
          assertThat(timer.elapsed(MILLISECONDS)).isAtLeast(10L);
    
          // If even the first one wasn't there, clean up so that the next test doesn't see an element.
          producerThread.cancel(true);
          producer.doneProducing.await();
          if (drained == 0) {
            q.poll(); // not necessarily there if producer was interrupted
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 12K bytes
    - Viewed (0)
  5. guava-testlib/src/com/google/common/collect/testing/FeatureSpecificTestSuiteBuilder.java

       * <p>Note: in principle this should never need to be used, but it might be useful if the
       * semantics of an implementation disagree in unforeseen ways with the semantics expected by a
       * test, or to keep dependent builds clean in spite of an erroneous test.
       */
      @CanIgnoreReturnValue
      public B suppressing(Method... methods) {
        return suppressing(Arrays.asList(methods));
      }
    
      @CanIgnoreReturnValue
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Feb 26 19:46:10 GMT 2024
    - 10.2K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/base/internal/Finalizer.java

            return false;
          }
        }
      }
    
      /**
       * Cleans up the given reference. Catches and logs all throwables.
       *
       * @return true if the caller should continue to clean up references from the queue, false if the
       *     associated FinalizableReferenceQueue is no longer referenced.
       */
      private boolean finalizeReference(Reference<?> reference, Method finalizeReferentMethod) {
        /*
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Aug 23 12:54:09 GMT 2023
    - 9.4K bytes
    - Viewed (0)
  7. android/guava-testlib/src/com/google/common/collect/testing/FeatureSpecificTestSuiteBuilder.java

       * <p>Note: in principle this should never need to be used, but it might be useful if the
       * semantics of an implementation disagree in unforeseen ways with the semantics expected by a
       * test, or to keep dependent builds clean in spite of an erroneous test.
       */
      @CanIgnoreReturnValue
      public B suppressing(Method... methods) {
        return suppressing(Arrays.asList(methods));
      }
    
      @CanIgnoreReturnValue
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Feb 26 19:46:10 GMT 2024
    - 10.2K bytes
    - Viewed (0)
  8. guava/src/com/google/common/cache/LocalCache.java

      }
    
      /**
       * Gets the value from an entry. Returns null if the entry is invalid, partially-collected,
       * loading, or expired. Unlike {@link Segment#getLiveValue} this method does not attempt to clean
       * up stale entries. As such it should only be called outside a segment context, such as during
       * iteration.
       */
      @CheckForNull
      V getLiveValue(ReferenceEntry<K, V> entry, long now) {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 150.3K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/collect/Sets.java

       * href="http://goo.gl/iz2Wi">"diamond" syntax</a>. One caveat to this is that the {@code TreeSet}
       * constructor uses a null {@code Comparator} to mean "natural ordering," whereas this factory
       * rejects null. Clean your code accordingly.
       *
       * @param comparator the comparator to use to sort the set
       * @return a new, empty {@code TreeSet}
       * @throws NullPointerException if {@code comparator} is null
       */
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 77.4K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/cache/LocalCache.java

      }
    
      /**
       * Gets the value from an entry. Returns null if the entry is invalid, partially-collected,
       * loading, or expired. Unlike {@link Segment#getLiveValue} this method does not attempt to clean
       * up stale entries. As such it should only be called outside a segment context, such as during
       * iteration.
       */
      @CheckForNull
      V getLiveValue(ReferenceEntry<K, V> entry, long now) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 144.7K bytes
    - Viewed (0)
Back to top