Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 108 for limits (0.32 sec)

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

             *
             * Ideally we'd have a real eviction policy, but until we see a problem in practice, I hope
             * that this will suffice. I have not even benchmarked with different size limits.
             */
            if (validClasses.size() > 1000) {
              validClasses.clear();
            }
    
            validClasses.add(new WeakReference<Class<? extends Exception>>(exceptionClass));
          }
        }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Dec 14 20:35:03 GMT 2023
    - 10.3K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/cache/CacheBuilderTest.java

      }
    
      /**
       * Calls get() repeatedly from many different threads, and tests that all of the removed entries
       * (removed because of size limits or expiration) trigger appropriate removal notifications.
       */
      @GwtIncompatible // QueuingRemovalListener
    
      public void testRemovalNotification_get_basher() throws InterruptedException {
        int nTasks = 1000;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Oct 03 20:10:02 GMT 2023
    - 23.2K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/escape/ArrayBasedUnicodeEscaper.java

        this.replacements = escaperMap.getReplacementArray();
        this.replacementsLength = replacements.length;
        if (safeMax < safeMin) {
          // If the safe range is empty, set the range limits to opposite extremes
          // to ensure the first test of either value will fail.
          safeMax = -1;
          safeMin = Integer.MAX_VALUE;
        }
        this.safeMin = safeMin;
        this.safeMax = safeMax;
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 8.5K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/cache/CacheBuilderTest.java

      }
    
      /**
       * Calls get() repeatedly from many different threads, and tests that all of the removed entries
       * (removed because of size limits or expiration) trigger appropriate removal notifications.
       */
      @GwtIncompatible // QueuingRemovalListener
    
      public void testRemovalNotification_get_basher() throws InterruptedException {
        int nTasks = 1000;
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Oct 03 20:10:02 GMT 2023
    - 25.5K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/collect/FluentIterableTest.java

        }
      }
    
      public void testLimit() {
        Iterable<String> iterable = Lists.newArrayList("foo", "bar", "baz");
        FluentIterable<String> limited = FluentIterable.from(iterable).limit(2);
    
        assertEquals(ImmutableList.of("foo", "bar"), Lists.newArrayList(limited));
        assertCanIterateAgain(limited);
        assertEquals("[foo, bar]", limited.toString());
      }
    
      public void testLimit_illegalArgument() {
        try {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Feb 06 18:35:19 GMT 2024
    - 31.1K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/hash/Java8Compatibility.java

    @ElementTypesAreNonnullByDefault
    final class Java8Compatibility {
      static void clear(Buffer b) {
        b.clear();
      }
    
      static void flip(Buffer b) {
        b.flip();
      }
    
      static void limit(Buffer b, int limit) {
        b.limit(limit);
      }
    
      static void position(Buffer b, int position) {
        b.position(position);
      }
    
      private Java8Compatibility() {}
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 20 18:43:59 GMT 2021
    - 1.2K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/hash/PrimitiveSink.java

      /**
       * Puts the remaining bytes of a byte buffer into this sink. {@code bytes.position()} is the first
       * byte written, {@code bytes.limit() - 1} is the last. The position of the buffer will be equal
       * to the limit when this method returns.
       *
       * @param bytes a byte buffer
       * @return this instance
       * @since 23.0
       */
      @CanIgnoreReturnValue
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Jun 15 20:59:00 GMT 2022
    - 3.9K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/hash/HashTestUtils.java

            int limit = pos + random.nextInt(value.length - pos + 1);
            for (PrimitiveSink sink : sinks) {
              ByteBuffer buffer = ByteBuffer.wrap(value);
              Java8Compatibility.position(buffer, pos);
              Java8Compatibility.limit(buffer, limit);
              sink.putBytes(buffer);
              assertEquals(limit, buffer.limit());
              assertEquals(limit, buffer.position());
            }
          }
    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)
  9. guava-tests/test/com/google/common/math/MathBenchmarking.java

       */
      static BigInteger randomNonNegativeBigInteger(int numBits) {
        int digits = RANDOM_SOURCE.nextInt(numBits);
        if (digits == 0) {
          return new BigInteger(1, RANDOM_SOURCE);
        } else {
          return new BigInteger(digits, RANDOM_SOURCE).setBit(digits);
        }
      }
    
      /**
       * Equivalent to calling randomPositiveBigInteger(numBits) and then flipping the sign with 50%
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 4.1K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/escape/Escapers.java

       * null} if no replacement should be made. This method is intended for use in tests through the
       * {@code EscaperAsserts} class; production users of {@link CharEscaper} should limit themselves
       * to its public interface.
       *
       * @param c the character to escape if necessary
       * @return the replacement string, or {@code null} if no escaping was needed
       */
      @CheckForNull
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Apr 26 20:07:17 GMT 2023
    - 10.5K bytes
    - Viewed (0)
Back to top