Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 32 for optimizations (0.31 sec)

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

        Appendable secretlyAWriter = new StringWriter();
        result = CharStreams.asWriter(secretlyAWriter);
        assertSame(secretlyAWriter, result);
      }
    
      // CharStreams.copy has type specific optimizations for Readers,StringBuilders and Writers
    
      public void testCopy() throws IOException {
        StringBuilder builder = new StringBuilder();
        long copied =
            CharStreams.copy(
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 11.2K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/io/CharStreamsTest.java

        Appendable secretlyAWriter = new StringWriter();
        result = CharStreams.asWriter(secretlyAWriter);
        assertSame(secretlyAWriter, result);
      }
    
      // CharStreams.copy has type specific optimizations for Readers,StringBuilders and Writers
    
      public void testCopy() throws IOException {
        StringBuilder builder = new StringBuilder();
        long copied =
            CharStreams.copy(
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 11.2K bytes
    - Viewed (0)
  3. guava/src/com/google/common/collect/AbstractMapBasedMultiset.java

          frequency.set(0);
        }
        backingMap.clear();
        size = 0L;
      }
    
      @Override
      int distinctElements() {
        return backingMap.size();
      }
    
      // Optimizations - Query Operations
    
      @Override
      public int size() {
        return Ints.saturatedCast(size);
      }
    
      @Override
      public Iterator<E> iterator() {
        return new MapBasedMultisetIterator();
      }
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Mar 06 16:06:58 GMT 2023
    - 10.4K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/RegularImmutableList.java

        checkElementIndex(index, size);
        // requireNonNull is safe because we guarantee that the first `size` elements are non-null.
        return (E) requireNonNull(array[index]);
      }
    
      // TODO(lowasser): benchmark optimizations for equals() and see if they're worthwhile
    
      // redeclare to help optimizers with b/310253115
      @SuppressWarnings("RedundantOverride")
      @Override
      @J2ktIncompatible // serialization
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Nov 30 21:54:06 GMT 2023
    - 2.8K bytes
    - Viewed (0)
  5. guava-gwt/src-super/com/google/common/util/concurrent/super/com/google/common/util/concurrent/AbstractFuture.java

        implements ListenableFuture<V> {
    
      static final boolean GENERATE_CANCELLATION_CAUSES = false;
    
      /**
       * Tag interface marking trusted subclasses. This enables some optimizations. The implementation
       * of this interface must also be an AbstractFuture and must not override or expose for overriding
       * any of the public methods of ListenableFuture.
       */
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Jan 22 19:37:41 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  6. guava-tests/benchmark/com/google/common/io/CharStreamsCopyBenchmark.java

    import java.io.StringWriter;
    import java.nio.Buffer;
    import java.nio.CharBuffer;
    import java.util.Random;
    
    /**
     * Benchmarks for {@link CharStreams#copy}.
     *
     * <p>{@link CharStreams#copy} has type specific optimizations for various common Appendable and
     * Reader implementations, this compares the performance of the different options.
     */
    // These benchmarks allocate a lot of data so use a large heap
    @VmOptions({"-Xms12g", "-Xmx12g", "-d64"})
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Feb 23 18:59:54 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  7. android/guava-tests/benchmark/com/google/common/io/CharStreamsCopyBenchmark.java

    import java.io.StringWriter;
    import java.nio.Buffer;
    import java.nio.CharBuffer;
    import java.util.Random;
    
    /**
     * Benchmarks for {@link CharStreams#copy}.
     *
     * <p>{@link CharStreams#copy} has type specific optimizations for various common Appendable and
     * Reader implementations, this compares the performance of the different options.
     */
    // These benchmarks allocate a lot of data so use a large heap
    @VmOptions({"-Xms12g", "-Xmx12g", "-d64"})
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 23 18:59:54 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/AggregateFuture.java

           * need access to the futures again, so we can just pass `null`.
           *
           * TODO(b/112550045): Allocating a single, cheaper listener is (I think) only an optimization.
           * If we make some other optimizations, this one will no longer be necessary. The optimization
           * could actually hurt in some cases, as it forces us to keep all inputs in memory until the
           * final input completes.
           */
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 01 21:46:34 GMT 2024
    - 15.4K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/graph/Graphs.java

       * be updated after modifications to {@code graph}.
       *
       * @since 33.1.0 (present with return type {@code Graph} since 20.0)
       */
      // TODO(b/31438252): Consider potential optimizations for this algorithm.
      public static <N> ImmutableGraph<N> transitiveClosure(Graph<N> graph) {
        ImmutableGraph.Builder<N> transitiveClosure =
            GraphBuilder.from(graph).allowsSelfLoops(true).<N>immutable();
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 21.2K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/collect/AbstractBiMap.java

        return new Inverse<>(backward, this);
      }
    
      void setInverse(AbstractBiMap<V, K> inverse) {
        this.inverse = inverse;
      }
    
      // Query Operations (optimizations)
    
      @Override
      public boolean containsValue(@CheckForNull Object value) {
        return inverse.containsKey(value);
      }
    
      // Modification Operations
    
      @CanIgnoreReturnValue
      @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Aug 24 01:40:03 GMT 2023
    - 13.8K bytes
    - Viewed (0)
Back to top