Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 60 for Total (0.13 sec)

  1. guava-tests/benchmark/com/google/common/base/SplitterBenchmark.java

      }
    
      @Benchmark
      void charSplitter(int reps) {
        int total = 0;
    
        for (int i = 0; i < reps; i++) {
          total += Iterables.size(CHAR_SPLITTER.split(input));
        }
      }
    
      @Benchmark
      void stringSplitter(int reps) {
        int total = 0;
    
        for (int i = 0; i < reps; i++) {
          total += Iterables.size(STRING_SPLITTER.split(input));
        }
      }
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 1.7K bytes
    - Viewed (0)
  2. android/guava-tests/benchmark/com/google/common/base/SplitterBenchmark.java

      }
    
      @Benchmark
      void charSplitter(int reps) {
        int total = 0;
    
        for (int i = 0; i < reps; i++) {
          total += Iterables.size(CHAR_SPLITTER.split(input));
        }
      }
    
      @Benchmark
      void stringSplitter(int reps) {
        int total = 0;
    
        for (int i = 0; i < reps; i++) {
          total += Iterables.size(STRING_SPLITTER.split(input));
        }
      }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 1.7K bytes
    - Viewed (0)
  3. guava-tests/benchmark/com/google/common/base/StopwatchBenchmark.java

    public class StopwatchBenchmark {
      @Benchmark
      long stopwatch(int reps) {
        long total = 0;
        for (int i = 0; i < reps; i++) {
          Stopwatch s = Stopwatch.createStarted();
          // here is where you would do something
          total += s.elapsed(TimeUnit.NANOSECONDS);
        }
        return total;
      }
    
      @Benchmark
      long manual(int reps) {
        long total = 0;
        for (int i = 0; i < reps; i++) {
          long start = System.nanoTime();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 1.5K bytes
    - Viewed (0)
  4. android/guava-tests/benchmark/com/google/common/base/StopwatchBenchmark.java

    public class StopwatchBenchmark {
      @Benchmark
      long stopwatch(int reps) {
        long total = 0;
        for (int i = 0; i < reps; i++) {
          Stopwatch s = Stopwatch.createStarted();
          // here is where you would do something
          total += s.elapsed(TimeUnit.NANOSECONDS);
        }
        return total;
      }
    
      @Benchmark
      long manual(int reps) {
        long total = 0;
        for (int i = 0; i < reps; i++) {
          long start = System.nanoTime();
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 1.5K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/collect/AbstractHashFloodingTest.java

        for (Construction<T> pathway : constructions) {
          smallCounter.zero();
          pathway.create(haveSameHashesSmall);
          long smallOps = smallCounter.total();
    
          largeCounter.zero();
          pathway.create(haveSameHashesLarge);
          long largeOps = largeCounter.total();
    
          double ratio = (double) largeOps / smallOps;
          assertWithMessage(
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Oct 03 21:01:39 GMT 2023
    - 8.6K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/io/CharStreams.java

          }
        }
    
        checkNotNull(from);
        checkNotNull(to);
        long total = 0;
        CharBuffer buf = createBuffer();
        while (from.read(buf) != -1) {
          Java8Compatibility.flip(buf);
          to.append(buf);
          total += buf.remaining();
          Java8Compatibility.clear(buf);
        }
        return total;
      }
    
      // TODO(lukes): consider allowing callers to pass in a buffer to use, some callers would be able
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed May 17 14:35:11 GMT 2023
    - 10.9K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/io/ByteStreams.java

        }
        checkPositionIndexes(off, off + len, b.length);
        int total = 0;
        while (total < len) {
          int result = in.read(b, off + total, len - total);
          if (result == -1) {
            break;
          }
          total += result;
        }
        return total;
      }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Jan 17 18:59:58 GMT 2024
    - 29.7K bytes
    - Viewed (0)
  8. guava/src/com/google/common/collect/ImmutableRangeSet.java

          Integer result = size;
          if (result == null) {
            long total = 0;
            for (Range<C> range : ranges) {
              total += ContiguousSet.create(range, domain).size();
              if (total >= Integer.MAX_VALUE) {
                break;
              }
            }
            result = size = Ints.saturatedCast(total);
          }
          return result.intValue();
        }
    
        @Override
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 26.9K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/collect/ImmutableRangeSet.java

          Integer result = size;
          if (result == null) {
            long total = 0;
            for (Range<C> range : ranges) {
              total += ContiguousSet.create(range, domain).size();
              if (total >= Integer.MAX_VALUE) {
                break;
              }
            }
            result = size = Ints.saturatedCast(total);
          }
          return result.intValue();
        }
    
        @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 27.2K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/collect/TreeMultiset.java

      private long aggregateForEntries(Aggregate aggr) {
        AvlNode<E> root = rootReference.get();
        long total = aggr.treeAggregate(root);
        if (range.hasLowerBound()) {
          total -= aggregateBelowRange(aggr, root);
        }
        if (range.hasUpperBound()) {
          total -= aggregateAboveRange(aggr, root);
        }
        return total;
      }
    
      private long aggregateBelowRange(Aggregate aggr, @CheckForNull AvlNode<E> node) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 34.2K bytes
    - Viewed (0)
Back to top