Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(80)

Side by Side Diff: components/cronet/android/api/src/org/chromium/net/ExperimentalBidirectionalStream.java

Issue 2339223002: Cronet API Refactoring (Closed)
Patch Set: Addressed some of the Paul's comments + rebase Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 package org.chromium.net;
6
7 /**
8 * {@link BidirectionalStream} that exposes experimental features.
9 * Created using {@link ExperimentalBidirectionalStream.Builder}.
pauljensen 2016/09/30 13:19:25 should we add "Every instance of {@link Bidirectio
kapishnikov 2016/09/30 16:01:43 Done.
10 *
11 * {@hide} as it's a prototype
12 */
13 public abstract class ExperimentalBidirectionalStream extends BidirectionalStrea m {
14 /**
15 * Builder for {@link ExperimentalBidirectionalStream}s. Allows configuring stream before
16 * constructing it via {@link Builder#build}.
17 */
18 public abstract static class Builder extends BidirectionalStream.Builder {
19 /**
20 * Associates the annotation object with this request. May add more than one.
21 * Passed through to a {@link RequestFinishedInfo.Listener},
22 * see {@link RequestFinishedInfo#getAnnotations}.
23 *
24 * @param annotation an object to pass on to the {@link RequestFinishedI nfo.Listener} with a
25 * {@link RequestFinishedInfo}.
26 * @return the builder to facilitate chaining.
27 */
28 public abstract Builder addRequestAnnotation(Object annotation);
29
30 // To support method chaining, override superclass methods to return an
31 // instance of this class instead of the parent.
32
33 @Override
34 public abstract Builder setHttpMethod(String method);
pauljensen 2016/09/30 13:19:25 how come there are abstract but ExperimentalCronet
kapishnikov 2016/09/30 16:01:43 ExperimentalCronetEngine.Builder is a concrete cla
35
36 @Override
37 public abstract Builder addHeader(String header, String value);
38
39 @Override
40 public abstract Builder setPriority(int priority);
41
42 @Override
43 public abstract Builder delayRequestHeadersUntilFirstFlush(
44 boolean delayRequestHeadersUntilFirstFlush);
45
46 @Override
47 public abstract ExperimentalBidirectionalStream build();
48 }
49 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698