Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 306 for enterIf (0.17 sec)

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

      protected final void tearDown() {
        tearDownStack.runTearDown();
      }
    
      private String enter() {
        return interruptible ? "enterInterruptibly" : "enter";
      }
    
      private String tryEnter() {
        return "tryEnter";
      }
    
      private String enterIf() {
        return interruptible ? "enterIfInterruptibly" : "enterIf";
      }
    
      private String tryEnterIf() {
        return "tryEnterIf";
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Apr 26 20:07:17 UTC 2023
    - 8K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/util/concurrent/MonitorTestCase.java

      protected final void tearDown() {
        tearDownStack.runTearDown();
      }
    
      private String enter() {
        return interruptible ? "enterInterruptibly" : "enter";
      }
    
      private String tryEnter() {
        return "tryEnter";
      }
    
      private String enterIf() {
        return interruptible ? "enterIfInterruptibly" : "enterIf";
      }
    
      private String tryEnterIf() {
        return "tryEnterIf";
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Apr 26 20:07:17 UTC 2023
    - 7.9K bytes
    - Viewed (0)
  3. guava-tests/benchmark/com/google/common/util/concurrent/MonitorBasedArrayBlockingQueue.java

       */
      @CanIgnoreReturnValue
      @Override
      public boolean offer(E e) {
        if (e == null) throw new NullPointerException();
        final Monitor monitor = this.monitor;
        if (monitor.enterIf(notFull)) {
          try {
            insert(e);
            return true;
          } finally {
            monitor.leave();
          }
        } else {
          return false;
        }
      }
    
      /**
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Apr 19 19:24:36 UTC 2023
    - 22.5K bytes
    - Viewed (0)
  4. android/guava-tests/benchmark/com/google/common/util/concurrent/MonitorBasedArrayBlockingQueue.java

       */
      @CanIgnoreReturnValue
      @Override
      public boolean offer(E e) {
        if (e == null) throw new NullPointerException();
        final Monitor monitor = this.monitor;
        if (monitor.enterIf(notFull)) {
          try {
            insert(e);
            return true;
          } finally {
            monitor.leave();
          }
        } else {
          return false;
        }
      }
    
      /**
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Apr 19 19:24:36 UTC 2023
    - 22.5K bytes
    - Viewed (0)
  5. guava/src/com/google/common/util/concurrent/Monitor.java

          }
        };
      }
    
      /** Enters this monitor. Blocks indefinitely. */
      public void enter() {
        lock.lock();
      }
    
      /**
       * Enters this monitor. Blocks at most the given time.
       *
       * @return whether the monitor was entered
       * @since 28.0
       */
      public boolean enter(Duration time) {
        return enter(toNanosSaturated(time), TimeUnit.NANOSECONDS);
      }
    
      /**
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Dec 04 18:22:01 UTC 2023
    - 42.5K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/util/concurrent/AbstractService.java

       *
       * @since 27.0
       */
      @ForOverride
      protected void doCancelStart() {}
    
      @CanIgnoreReturnValue
      @Override
      public final Service startAsync() {
        if (monitor.enterIf(isStartable)) {
          try {
            snapshot = new StateSnapshot(STARTING);
            enqueueStartingEvent();
            doStart();
          } catch (Throwable startupFailure) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri May 12 18:32:03 UTC 2023
    - 20.4K bytes
    - Viewed (0)
  7. guava/src/com/google/common/util/concurrent/AbstractService.java

       *
       * @since 27.0
       */
      @ForOverride
      protected void doCancelStart() {}
    
      @CanIgnoreReturnValue
      @Override
      public final Service startAsync() {
        if (monitor.enterIf(isStartable)) {
          try {
            snapshot = new StateSnapshot(STARTING);
            enqueueStartingEvent();
            doStart();
          } catch (Throwable startupFailure) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri May 12 18:32:03 UTC 2023
    - 20.7K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/Monitor.java

        this.lock = new ReentrantLock(fair);
      }
    
      /** Enters this monitor. Blocks indefinitely. */
      public void enter() {
        lock.lock();
      }
    
      /**
       * Enters this monitor. Blocks at most the given time.
       *
       * @return whether the monitor was entered
       */
      @SuppressWarnings("GoodTime") // should accept a java.time.Duration
      public boolean enter(long time, TimeUnit unit) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Dec 04 18:22:01 UTC 2023
    - 38.6K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/util/concurrent/GeneratedMonitorTest.java

       * methods that do not take an explicit timeout value, a single test case is generated only if the
       * implicit timeout of that method matches the given timeoutsToUse. For example, enter() is
       * treated like enter(MAX, MILLIS) and tryEnter() is treated like enter(0, MILLIS).
       */
      private static void addTests(
          TestSuite suite,
          Method method,
          Scenario scenario,
          TimeoutsToUse timeoutsToUse,
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed May 29 16:29:37 UTC 2024
    - 25.8K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/util/concurrent/GeneratedMonitorTest.java

       * methods that do not take an explicit timeout value, a single test case is generated only if the
       * implicit timeout of that method matches the given timeoutsToUse. For example, enter() is
       * treated like enter(MAX, MILLIS) and tryEnter() is treated like enter(0, MILLIS).
       */
      private static void addTests(
          TestSuite suite,
          Method method,
          Scenario scenario,
          TimeoutsToUse timeoutsToUse,
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed May 29 16:29:37 UTC 2024
    - 27.1K bytes
    - Viewed (0)
Back to top