Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for casWaiters (0.27 sec)

  1. android/guava/src/com/google/common/util/concurrent/AbstractFuture.java

        }
    
        /** Performs a GAS operation on the {@link #waiters} field. */
        @Override
        Waiter gasWaiters(AbstractFuture<?> future, Waiter update) {
          while (true) {
            Waiter waiter = future.waiters;
            if (update == waiter) {
              return waiter;
            }
            if (casWaiters(future, waiter, update)) {
              return waiter;
            }
          }
        }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 21:17:24 GMT 2024
    - 63K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/util/concurrent/TestThread.java

        checkNotNull(conditionLikeObject);
        // TODO: Restore the following line when Monitor.hasWaiters() no longer acquires the lock.
        // assertEquals(false, invokeMethod("hasWaiters", conditionLikeObject));
        sendRequest(methodName, conditionLikeObject);
        Thread.sleep(DUE_DILIGENCE_MILLIS);
        assertEquals(true, invokeMethod("hasWaiters", conditionLikeObject));
        assertNull(responseQueue.poll());
      }
    
      /**
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Apr 26 20:07:17 GMT 2023
    - 10.9K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/util/concurrent/TestThread.java

        checkNotNull(conditionLikeObject);
        // TODO: Restore the following line when Monitor.hasWaiters() no longer acquires the lock.
        // assertEquals(false, invokeMethod("hasWaiters", conditionLikeObject));
        sendRequest(methodName, conditionLikeObject);
        Thread.sleep(DUE_DILIGENCE_MILLIS);
        assertEquals(true, invokeMethod("hasWaiters", conditionLikeObject));
        assertNull(responseQueue.poll());
      }
    
      /**
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Apr 26 20:07:17 GMT 2023
    - 10.9K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/util/concurrent/SupplementalMonitorTest.java

        Monitor monitor1 = new Monitor();
        Monitor monitor2 = new Monitor();
        FlagGuard guard = new FlagGuard(monitor2);
        assertThrows(IllegalMonitorStateException.class, () -> monitor1.hasWaiters(guard));
      }
    
      public void testNullMonitorInGuardConstructorThrowsNPE() {
        assertThrows(NullPointerException.class, () -> new FlagGuard(null));
      }
    
      public void testIsFair() {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 4.9K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/util/concurrent/SupplementalMonitorTest.java

        Monitor monitor1 = new Monitor();
        Monitor monitor2 = new Monitor();
        FlagGuard guard = new FlagGuard(monitor2);
        assertThrows(IllegalMonitorStateException.class, () -> monitor1.hasWaiters(guard));
      }
    
      public void testNullMonitorInGuardConstructorThrowsNPE() {
        assertThrows(NullPointerException.class, () -> new FlagGuard(null));
      }
    
      public void testIsFair() {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 4.9K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/util/concurrent/Monitor.java

       * and leaves, calling signalNextWaiter. With traditional locks and conditions, all the conditions
       * need to be signalled because it is not known which if any of them have waiters (and hasWaiters
       * can't be used reliably because of a check-then-act race). With our Monitor guards, we only
       * signal the first active guard that is satisfied. But the corresponding thread may have already
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Dec 04 18:22:01 GMT 2023
    - 38.6K bytes
    - Viewed (0)
Back to top