Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 1,193 for rint (0.12 sec)

  1. android/guava-tests/test/com/google/common/io/LineBufferTest.java

      private static Readable getChunkedReadable(String input, int chunk) {
        final Reader reader = getChunkedReader(input, chunk);
        return new Readable() {
          @Override
          public int read(CharBuffer cbuf) throws IOException {
            return reader.read(cbuf);
          }
        };
      }
    
      private static Reader getChunkedReader(String input, final int chunk) {
        return new FilterReader(new StringReader(input)) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 4.7K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/primitives/ImmutableDoubleArray.java

        }
    
        private void ensureRoomFor(int numberToAdd) {
          int newCount = count + numberToAdd; // TODO(kevinb): check overflow now?
          if (newCount > array.length) {
            array = Arrays.copyOf(array, expandedCapacity(array.length, newCount));
          }
        }
    
        // Unfortunately this is pasted from ImmutableCollection.Builder.
        private static int expandedCapacity(int oldCapacity, int minCapacity) {
          if (minCapacity < 0) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 16:34:24 GMT 2023
    - 19.6K bytes
    - Viewed (0)
  3. guava-tests/benchmark/com/google/common/util/concurrent/MonitorBenchmark.java

        Constructor<?> constructor = Class.forName(className).getConstructor(int.class);
        queue = (BlockingQueue<String>) constructor.newInstance(capacity);
    
        strings = new String[capacity];
        for (int i = 0; i < capacity; i++) {
          strings[i] = String.valueOf(Math.random());
        }
      }
    
      @Benchmark
      void addsAndRemoves(int reps) {
        int capacity = this.capacity;
        BlockingQueue<String> queue = this.queue;
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 2K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/hash/MessageDigestHashFunction.java

        private final int bytes;
        private boolean done;
    
        private MessageDigestHasher(MessageDigest digest, int bytes) {
          this.digest = digest;
          this.bytes = bytes;
        }
    
        @Override
        protected void update(byte b) {
          checkNotDone();
          digest.update(b);
        }
    
        @Override
        protected void update(byte[] b, int off, int len) {
          checkNotDone();
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed May 25 20:32:46 GMT 2022
    - 5K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/collect/ForwardingMultisetTest.java

          return standardEquals(object);
        }
    
        @Override
        public int hashCode() {
          return standardHashCode();
        }
    
        @Override
        public boolean setCount(T element, int oldCount, int newCount) {
          return standardSetCount(element, oldCount, newCount);
        }
    
        @Override
        public int setCount(T element, int count) {
          return standardSetCount(element, count);
        }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Apr 17 15:49:06 GMT 2023
    - 11.8K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/Multisets.java

      }
    
      /** An implementation of {@link Multiset#setCount(Object, int)}. */
      static <E extends @Nullable Object> int setCountImpl(
          Multiset<E> self, @ParametricNullness E element, int count) {
        checkNonnegative(count, "count");
    
        int oldCount = self.count(element);
    
        int delta = count - oldCount;
        if (delta > 0) {
          self.add(element, delta);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 41.7K bytes
    - Viewed (0)
  7. guava-tests/benchmark/com/google/common/hash/HashCodeBenchmark.java

            }
            return (result == 0);
          }
        },
        XORING_TO_INT {
          @Override
          boolean doEquals(byte[] a, byte[] b) {
            if (a.length != b.length) {
              return false;
            }
            int result = 0;
            for (int i = 0; i < a.length; i++) {
              result |= a[i] ^ b[i];
            }
            return (result == 0);
          }
        },
        MESSAGE_DIGEST_IS_EQUAL {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 3.9K bytes
    - Viewed (0)
  8. android/guava-tests/benchmark/com/google/common/base/ToStringHelperBenchmark.java

        if (omitNulls) {
          helper = helper.omitNullValues();
        }
        return helper;
      }
    
      @Benchmark
      int toString(int reps) {
        int dummy = 0;
        for (int i = 0; i < reps; i++) {
          MoreObjects.ToStringHelper helper = newHelper();
          for (int j = 0; j < dataSize; ++j) {
            dataset.addEntries(helper);
          }
          dummy ^= helper.toString().hashCode();
        }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri May 14 22:05:11 GMT 2021
    - 4.3K bytes
    - Viewed (0)
  9. android/guava-tests/benchmark/com/google/common/hash/HashCodeBenchmark.java

            }
            return (result == 0);
          }
        },
        XORING_TO_INT {
          @Override
          boolean doEquals(byte[] a, byte[] b) {
            if (a.length != b.length) {
              return false;
            }
            int result = 0;
            for (int i = 0; i < a.length; i++) {
              result |= a[i] ^ b[i];
            }
            return (result == 0);
          }
        },
        MESSAGE_DIGEST_IS_EQUAL {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 3.9K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/graph/GraphMutationTest.java

    @RunWith(JUnit4.class)
    
    public final class GraphMutationTest {
      private static final int NUM_TRIALS = 50;
      private static final int NUM_NODES = 100;
      private static final int NUM_EDGES = 1000;
      private static final int NODE_POOL_SIZE = 1000; // must be >> NUM_NODES
    
      @Test
      public void directedGraph() {
        testGraphMutation(GraphBuilder.directed());
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri Aug 18 16:17:46 GMT 2017
    - 4.2K bytes
    - Viewed (0)
Back to top