Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for nextBoolean (0.07 sec)

  1. guava-tests/test/com/google/common/math/MathBenchmarking.java

        return RANDOM_SOURCE.nextBoolean() ? result : result.negate();
      }
    
      /**
       * Chooses a number in (-2^numBits, 2^numBits) at random, with density concentrated in numbers of
       * lower magnitude.
       */
      static BigInteger randomBigInteger(int numBits) {
        while (true) {
          if (RANDOM_SOURCE.nextBoolean()) {
            return randomNonNegativeBigInteger(numBits);
          }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 4.1K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/math/MathBenchmarking.java

        return RANDOM_SOURCE.nextBoolean() ? result : result.negate();
      }
    
      /**
       * Chooses a number in (-2^numBits, 2^numBits) at random, with density concentrated in numbers of
       * lower magnitude.
       */
      static BigInteger randomBigInteger(int numBits) {
        while (true) {
          if (RANDOM_SOURCE.nextBoolean()) {
            return randomNonNegativeBigInteger(numBits);
          }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 4.1K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/collect/MinMaxPriorityQueueTest.java

        for (int i = 0; i < numberOfModifications; i++) {
          if (random.nextBoolean()) {
            /* insert a new element */
            int randomInt = random.nextInt();
            mmHeap.offer(randomInt);
            insertIntoReplica(replica, randomInt);
            currentHeapSize++;
          } else {
            /* remove either min or max */
            if (random.nextBoolean()) {
              removeMinFromReplica(replica, mmHeap.poll());
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 35.9K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/collect/MinMaxPriorityQueueTest.java

        for (int i = 0; i < numberOfModifications; i++) {
          if (random.nextBoolean()) {
            /* insert a new element */
            int randomInt = random.nextInt();
            mmHeap.offer(randomInt);
            insertIntoReplica(replica, randomInt);
            currentHeapSize++;
          } else {
            /* remove either min or max */
            if (random.nextBoolean()) {
              removeMinFromReplica(replica, mmHeap.poll());
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 35.9K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/hash/HashTestUtils.java

            }
          };
    
      enum RandomHasherAction {
        PUT_BOOLEAN() {
          @Override
          void performAction(Random random, Iterable<? extends PrimitiveSink> sinks) {
            boolean value = random.nextBoolean();
            for (PrimitiveSink sink : sinks) {
              sink.putBoolean(value);
            }
          }
        },
        PUT_BYTE() {
          @Override
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Jul 23 14:22:54 UTC 2024
    - 25.5K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/cache/LocalCacheTest.java

          Iterator<ReferenceEntry<Object, Object>> i = readOrder.iterator();
          while (i.hasNext()) {
            ReferenceEntry<Object, Object> entry = i.next();
            if (random.nextBoolean()) {
              map.get(entry.getKey(), loader);
              reads.add(entry);
              i.remove();
              assertTrue(segment.recencyQueue.size() <= DRAIN_THRESHOLD);
            }
          }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 19:07:49 UTC 2024
    - 110.6K bytes
    - Viewed (0)
  7. guava-tests/test/com/google/common/cache/LocalCacheTest.java

          Iterator<ReferenceEntry<Object, Object>> i = readOrder.iterator();
          while (i.hasNext()) {
            ReferenceEntry<Object, Object> entry = i.next();
            if (random.nextBoolean()) {
              map.get(entry.getKey(), loader);
              reads.add(entry);
              i.remove();
              assertTrue(segment.recencyQueue.size() <= DRAIN_THRESHOLD);
            }
          }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 19:07:49 UTC 2024
    - 112.3K bytes
    - Viewed (0)
Back to top