Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 13 for AtomicLong (0.25 sec)

  1. guava-tests/test/com/google/common/primitives/ImmutableLongArrayTest.java

       */
      public void testBuilder_bruteForce() {
        for (int i = 0; i < reduceIterationsIfGwt(100); i++) {
          ImmutableLongArray.Builder builder = ImmutableLongArray.builder(RANDOM.nextInt(20));
          AtomicLong counter = new AtomicLong(0);
          while (counter.get() < 1000) {
            BuilderOp op = BuilderOp.randomOp();
            op.doIt(builder, counter);
          }
          ImmutableLongArray iia = builder.build();
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Thu Jun 01 09:32:35 GMT 2023
    - 20.2K bytes
    - Viewed (0)
  2. android/guava-testlib/src/com/google/common/testing/FakeTicker.java

     * <p>This class is thread-safe.
     *
     * @author Jige Yu
     * @since 10.0
     */
    @ElementTypesAreNonnullByDefault
    @GwtCompatible
    public class FakeTicker extends Ticker {
    
      private final AtomicLong nanos = new AtomicLong();
      private volatile long autoIncrementStepNanos;
    
      /** Advances the ticker value by {@code time} in {@code timeUnit}. */
      @SuppressWarnings("GoodTime") // should accept a java.time.Duration
      @CanIgnoreReturnValue
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Mar 13 18:17:09 GMT 2024
    - 4.2K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/primitives/ImmutableLongArrayTest.java

       */
      public void testBuilder_bruteForce() {
        for (int i = 0; i < reduceIterationsIfGwt(100); i++) {
          ImmutableLongArray.Builder builder = ImmutableLongArray.builder(RANDOM.nextInt(20));
          AtomicLong counter = new AtomicLong(0);
          while (counter.get() < 1000) {
            BuilderOp op = BuilderOp.randomOp();
            op.doIt(builder, counter);
          }
          ImmutableLongArray iia = builder.build();
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Jun 01 09:32:35 GMT 2023
    - 19K bytes
    - Viewed (0)
  4. guava-testlib/src/com/google/common/testing/FakeTicker.java

     * <p>This class is thread-safe.
     *
     * @author Jige Yu
     * @since 10.0
     */
    @ElementTypesAreNonnullByDefault
    @GwtCompatible
    public class FakeTicker extends Ticker {
    
      private final AtomicLong nanos = new AtomicLong();
      private volatile long autoIncrementStepNanos;
    
      /** Advances the ticker value by {@code time} in {@code timeUnit}. */
      @SuppressWarnings("GoodTime") // should accept a java.time.Duration
      @CanIgnoreReturnValue
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Feb 06 14:40:46 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/util/concurrent/ThreadFactoryBuilder.java

        ThreadFactory backingThreadFactory =
            (builder.backingThreadFactory != null)
                ? builder.backingThreadFactory
                : Executors.defaultThreadFactory();
        AtomicLong count = (nameFormat != null) ? new AtomicLong(0) : null;
        return new ThreadFactory() {
          @Override
          public Thread newThread(Runnable runnable) {
            Thread thread = backingThreadFactory.newThread(runnable);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed May 10 21:56:03 GMT 2023
    - 7.6K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/cache/Striped64.java

       * is a power of two. Indexing uses masked per-thread hash codes.
       * Nearly all declarations in this class are package-private,
       * accessed directly by subclasses.
       *
       * Table entries are of class Cell; a variant of AtomicLong padded
       * to reduce cache contention on most processors. Padding is
       * overkill for most Atomics because they are usually irregularly
       * scattered in memory and thus don't interfere much with each
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 11.5K bytes
    - Viewed (0)
  7. guava-testlib/test/com/google/common/testing/ArbitraryInstancesTest.java

    import java.util.concurrent.ThreadFactory;
    import java.util.concurrent.TimeUnit;
    import java.util.concurrent.atomic.AtomicBoolean;
    import java.util.concurrent.atomic.AtomicInteger;
    import java.util.concurrent.atomic.AtomicLong;
    import java.util.concurrent.atomic.AtomicReference;
    import java.util.regex.MatchResult;
    import java.util.regex.Pattern;
    import junit.framework.TestCase;
    import org.checkerframework.checker.nullness.qual.Nullable;
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 22.1K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/AtomicLongMap.java

       * zero values have been removed and others have not.
       */
      public void removeAllZeros() {
        Iterator<Entry<K, AtomicLong>> entryIterator = map.entrySet().iterator();
        while (entryIterator.hasNext()) {
          Entry<K, AtomicLong> entry = entryIterator.next();
          AtomicLong atomic = entry.getValue();
          if (atomic != null && atomic.get() == 0L) {
            entryIterator.remove();
          }
        }
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 14.1K bytes
    - Viewed (0)
  9. guava/src/com/google/common/cache/Striped64.java

       * is a power of two. Indexing uses masked per-thread hash codes.
       * Nearly all declarations in this class are package-private,
       * accessed directly by subclasses.
       *
       * Table entries are of class Cell; a variant of AtomicLong padded
       * to reduce cache contention on most processors. Padding is
       * overkill for most Atomics because they are usually irregularly
       * scattered in memory and thus don't interfere much with each
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 11.5K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/hash/Striped64.java

       * is a power of two. Indexing uses masked per-thread hash codes.
       * Nearly all declarations in this class are package-private,
       * accessed directly by subclasses.
       *
       * Table entries are of class Cell; a variant of AtomicLong padded
       * to reduce cache contention on most processors. Padding is
       * overkill for most Atomics because they are usually irregularly
       * scattered in memory and thus don't interfere much with each
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 11.5K bytes
    - Viewed (0)
Back to top