Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 40 for Rate (0.29 sec)

  1. android/guava/src/com/google/common/math/LinearTransformation.java

            return new VerticalLinearTransformation(x1);
          } else {
            return withSlope((y2 - y1) / (x2 - x1));
          }
        }
    
        /**
         * Finish building an instance with the given slope, i.e. the rate of change of {@code y} with
         * respect to {@code x}. The slope must not be {@code NaN}. It may be infinite, in which case
         * the transformation is vertical. (If it is zero, the transformation is horizontal.)
         */
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 17:02:53 GMT 2023
    - 9.6K bytes
    - Viewed (0)
  2. guava-tests/benchmark/com/google/common/cache/LoadingCacheSingleThreadBenchmark.java

      int maximumSize;
    
      @Param("5000")
      int distinctKeys;
    
      @Param("4")
      int segments;
    
      // 1 means uniform likelihood of keys; higher means some keys are more popular
      // tweak this to control hit rate
      @Param("2.5")
      double concentration;
    
      Random random = new Random();
    
      LoadingCache<Integer, Integer> cache;
    
      int max;
    
      static AtomicLong requests = new AtomicLong(0);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 3.4K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/util/concurrent/RateLimiter.java

     * <p>Rate limiters are often used to restrict the rate at which some physical or logical resource
     * is accessed. This is in contrast to {@link java.util.concurrent.Semaphore} which restricts the
     * number of concurrent accesses instead of the rate (note though that concurrency and rate are
     * closely related, e.g. see <a href="http://en.wikipedia.org/wiki/Little%27s_law">Little's
     * Law</a>).
     *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 04 09:45:04 GMT 2023
    - 18.2K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/util/concurrent/AbstractScheduledService.java

     * late. Also, all life cycle methods are executed with a lock held, so subclasses can safely modify
     * shared state without additional synchronization necessary for visibility to later executions of
     * the life cycle methods.
     *
     * <h3>Usage Example</h3>
     *
     * <p>Here is a sketch of a service which crawls a website and uses the scheduling capabilities to
     * rate limit itself.
     *
     * <pre>{@code
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Dec 13 19:45:20 GMT 2023
    - 25.8K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/RateLimiterTest.java

       * we change the rate.
       */
      public void testWeNeverGetABurstMoreThanOneSec() {
        RateLimiter limiter = RateLimiter.create(1.0, stopwatch);
        int[] rates = {1000, 1, 10, 1000000, 10, 1};
        for (int rate : rates) {
          int oneSecWorthOfWork = rate;
          stopwatch.sleepMillis(rate * 1000);
          limiter.setRate(rate);
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 21.6K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/util/concurrent/SmoothRateLimiter.java

       * underlying model is a continuous function mapping storedPermits (from 0.0 to maxStoredPermits)
       * onto the 1/rate (i.e. intervals) that is effective at the given storedPermits. "storedPermits"
       * essentially measure unused time; we spend unused time buying/storing permits. Rate is
       * "permits / time", thus "1 / rate = time / permits". Thus, "1/rate" (time / permits) times
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 04 09:45:04 GMT 2023
    - 19.3K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/util/concurrent/RateLimiterTest.java

       * we change the rate.
       */
      public void testWeNeverGetABurstMoreThanOneSec() {
        RateLimiter limiter = RateLimiter.create(1.0, stopwatch);
        int[] rates = {1000, 1, 10, 1000000, 10, 1};
        for (int rate : rates) {
          int oneSecWorthOfWork = rate;
          stopwatch.sleepMillis(rate * 1000);
          limiter.setRate(rate);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 21.6K bytes
    - Viewed (0)
  8. android/guava-tests/benchmark/com/google/common/cache/LoadingCacheSingleThreadBenchmark.java

      int maximumSize;
    
      @Param("5000")
      int distinctKeys;
    
      @Param("4")
      int segments;
    
      // 1 means uniform likelihood of keys; higher means some keys are more popular
      // tweak this to control hit rate
      @Param("2.5")
      double concentration;
    
      Random random = new Random();
    
      LoadingCache<Integer, Integer> cache;
    
      int max;
    
      static AtomicLong requests = new AtomicLong(0);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 3.4K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/io/testdata/alice_in_wonderland.txt

    Rabbit with pink eyes ran close by her.
    
      There was nothing so VERY remarkable in that; nor did Alice
    think it so VERY much out of the way to hear the Rabbit say to
    itself, `Oh dear!  Oh dear!  I shall be late!'  (when she thought
    it over afterwards, it occurred to her that she ought to have
    wondered at this, but at the time it all seemed quite natural);
    but when the Rabbit actually TOOK A WATCH OUT OF ITS WAISTCOAT-
    Plain Text
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Apr 21 02:27:51 GMT 2017
    - 145.2K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/hash/HashTestUtils.java

              Assert.assertEquals(0.50d, prob, epsilon);
            }
          }
        }
      }
    
      /**
       * Checks that a Hasher returns the same HashCode when given the same input, and also that the
       * collision rate looks sane.
       */
      static void assertInvariants(HashFunction hashFunction) {
        int objects = 100;
        Set<HashCode> hashcodes = Sets.newHashSetWithExpectedSize(objects);
        Random random = new Random(314159);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 25.3K bytes
    - Viewed (0)
Back to top