Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for newReentrantLock (0.2 sec)

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

        lock1 = factory2.newReentrantLock(MyOrder.FIRST);
        lock2 = factory2.newReentrantLock(MyOrder.SECOND);
        lock3 = factory2.newReentrantLock(MyOrder.THIRD);
    
        CycleDetectingLockFactory.WithExplicitOrdering<OtherOrder> factory3 =
            newInstanceWithExplicitOrdering(OtherOrder.class, Policies.THROW);
        lock01 = factory3.newReentrantLock(OtherOrder.FIRST);
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 16.1K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/util/concurrent/CycleDetectingLockFactoryTest.java

        lock1 = factory2.newReentrantLock(MyOrder.FIRST);
        lock2 = factory2.newReentrantLock(MyOrder.SECOND);
        lock3 = factory2.newReentrantLock(MyOrder.THIRD);
    
        CycleDetectingLockFactory.WithExplicitOrdering<OtherOrder> factory3 =
            newInstanceWithExplicitOrdering(OtherOrder.class, Policies.THROW);
        lock01 = factory3.newReentrantLock(OtherOrder.FIRST);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 16.1K bytes
    - Viewed (1)
  3. android/guava/src/com/google/common/util/concurrent/CycleDetectingLockFactory.java

      public static CycleDetectingLockFactory newInstance(Policy policy) {
        return new CycleDetectingLockFactory(policy);
      }
    
      /** Equivalent to {@code newReentrantLock(lockName, false)}. */
      public ReentrantLock newReentrantLock(String lockName) {
        return newReentrantLock(lockName, false);
      }
    
      /**
       * Creates a {@link ReentrantLock} with the given fairness policy. The {@code lockName} is used in
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Dec 15 19:31:54 GMT 2023
    - 35.9K bytes
    - Viewed (0)
  4. android/guava-tests/benchmark/com/google/common/util/concurrent/CycleDetectingLockFactoryBenchmark.java

        for (int i = 0; i < lockNestingDepth; i++) {
          detectingLocks[i] = factory.newReentrantLock("Lock" + i);
        }
      }
    
      @Benchmark
      void unorderedPlainLocks(int reps) {
        lockAndUnlock(new ReentrantLock(), reps);
      }
    
      @Benchmark
      void unorderedCycleDetectingLocks(int reps) {
        lockAndUnlock(factory.newReentrantLock("foo"), reps);
      }
    
      private static void lockAndUnlock(Lock lock, int reps) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 2.4K bytes
    - Viewed (0)
  5. guava-tests/benchmark/com/google/common/util/concurrent/CycleDetectingLockFactoryBenchmark.java

        for (int i = 0; i < lockNestingDepth; i++) {
          detectingLocks[i] = factory.newReentrantLock("Lock" + i);
        }
      }
    
      @Benchmark
      void unorderedPlainLocks(int reps) {
        lockAndUnlock(new ReentrantLock(), reps);
      }
    
      @Benchmark
      void unorderedCycleDetectingLocks(int reps) {
        lockAndUnlock(factory.newReentrantLock("foo"), reps);
      }
    
      private static void lockAndUnlock(Lock lock, int reps) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 2.4K bytes
    - Viewed (0)
Back to top