Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 567 for Rock (0.16 sec)

  1. android/guava-tests/test/com/google/common/util/concurrent/WrappingExecutorServiceTest.java

        MockExecutor mock = new MockExecutor();
        TestExecutor testExecutor = new TestExecutor(mock);
        assertFalse(testExecutor.awaitTermination(10, TimeUnit.MILLISECONDS));
        mock.assertLastMethodCalled("awaitTermination");
        assertFalse(testExecutor.isTerminated());
        mock.assertLastMethodCalled("isTerminated");
        assertFalse(testExecutor.isShutdown());
        mock.assertLastMethodCalled("isShutdown");
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Jan 05 19:41:03 GMT 2023
    - 9.8K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/util/concurrent/ForwardingLock.java

    import java.util.concurrent.locks.Condition;
    import java.util.concurrent.locks.Lock;
    
    /** Forwarding wrapper around a {@code Lock}. */
    @J2ktIncompatible
    @ElementTypesAreNonnullByDefault
    abstract class ForwardingLock implements Lock {
      abstract Lock delegate();
    
      @Override
      public void lock() {
        delegate().lock();
      }
    
      @Override
      public void lockInterruptibly() throws InterruptedException {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 04 09:45:04 GMT 2023
    - 1.5K bytes
    - Viewed (0)
  3. internal/dsync/lock-args_gen_test.go

    Klaus Post <******@****.***> 1700528975 -0800
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Nov 21 01:09:35 GMT 2023
    - 4.4K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/util/concurrent/WrappingScheduledExecutorServiceTest.java

          };
    
      public void testSchedule() {
        MockExecutor mock = new MockExecutor();
        TestExecutor testExecutor = new TestExecutor(mock);
    
        @SuppressWarnings("unused") // https://errorprone.info/bugpattern/FutureReturnValueIgnored
        Future<?> possiblyIgnoredError = testExecutor.schedule(DO_NOTHING, 10, TimeUnit.MINUTES);
        mock.assertLastMethodCalled("scheduleRunnable", 10, TimeUnit.MINUTES);
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Dec 16 19:54:45 GMT 2020
    - 7.6K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/cache/ForwardingCacheTest.java

         * the type is irrelevant at runtime.
         */
        mock = mock(Cache.class);
        forward =
            new ForwardingCache<String, Boolean>() {
              @Override
              protected Cache<String, Boolean> delegate() {
                return mock;
              }
            };
      }
    
      public void testGetIfPresent() throws ExecutionException {
        when(mock.getIfPresent("key")).thenReturn(Boolean.TRUE);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Apr 17 12:41:04 GMT 2023
    - 3.1K bytes
    - Viewed (0)
  6. internal/dsync/dsync_test.go

    	dm1st := NewDRWMutex(ds, "aap")
    	dm2nd := NewDRWMutex(ds, "aap")
    
    	dm1st.Lock(id, source)
    
    	// Release lock after 10 seconds
    	go func() {
    		time.Sleep(5 * testDrwMutexAcquireTimeout)
    		// fmt.Println("Unlocking dm1")
    
    		dm1st.Unlock(context.Background())
    	}()
    
    	dm2nd.Lock(id, source)
    
    	// fmt.Printf("2nd lock obtained after 1st lock is released\n")
    	time.Sleep(testDrwMutexRefreshCallTimeout * 2)
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Dec 24 03:49:07 GMT 2022
    - 11K bytes
    - Viewed (0)
  7. internal/lsync/lrwmutex.go

    }
    
    // RLock holds a read lock on lm.
    //
    // If one or more read lock are already in use, it will grant another lock.
    // Otherwise the calling go routine blocks until the mutex is available.
    func (lm *LRWMutex) RLock() {
    	const isWriteLock = false
    	lm.lockLoop(context.Background(), lm.id, lm.source, 1<<63-1, isWriteLock)
    }
    
    // GetRLock tries to get a read lock on lm before the timeout occurs.
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Sun Jan 02 17:15:06 GMT 2022
    - 4.8K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/cache/ForwardingLoadingCacheTest.java

         * the type is irrelevant at runtime.
         */
        mock = mock(LoadingCache.class);
        forward =
            new ForwardingLoadingCache<String, Boolean>() {
              @Override
              protected LoadingCache<String, Boolean> delegate() {
                return mock;
              }
            };
      }
    
      public void testGet() throws ExecutionException {
        when(mock.get("key")).thenReturn(Boolean.TRUE);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Apr 17 12:41:04 GMT 2023
    - 3.4K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/io/FlushablesTest.java

        // 'swallowException' when the mock does not throw an exception.
        setupFlushable(false);
        doFlush(mockFlushable, false, false);
    
        setupFlushable(false);
        doFlush(mockFlushable, true, false);
      }
    
      public void testFlush_flushableWithEatenException() throws IOException {
        // make sure that no exception is thrown if 'swallowException' is true
        // when the mock does throw an exception on flush.
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 3.3K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/util/concurrent/UninterruptiblesTest.java

        }
    
        static TestCondition create() {
          Lock lock = new ReentrantLock();
          Condition condition = lock.newCondition();
          return new TestCondition(lock, condition);
        }
    
        @Override
        public void await() throws InterruptedException {
          lock.lock();
          try {
            condition.await();
          } finally {
            lock.unlock();
          }
        }
    
        @Override
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Feb 09 22:57:07 GMT 2022
    - 31.7K bytes
    - Viewed (0)
Back to top