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

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

Issue 2444083002: Fix addRequestFinishedListener() documentation (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package org.chromium.net; 5 package org.chromium.net;
6 6
7 import android.annotation.SuppressLint; 7 import android.annotation.SuppressLint;
8 import android.content.Context; 8 import android.content.Context;
9 import android.net.http.HttpResponseCache; 9 import android.net.http.HttpResponseCache;
10 import android.support.annotation.IntDef; 10 import android.support.annotation.IntDef;
(...skipping 1152 matching lines...) Expand 10 before | Expand all | Expand 10 after
1163 // Leave as null. 1163 // Leave as null.
1164 } catch (Exception e) { 1164 } catch (Exception e) {
1165 throw new IllegalStateException("Cannot instantiate: " + CRONET_URL_ REQUEST_CONTEXT, e); 1165 throw new IllegalStateException("Cannot instantiate: " + CRONET_URL_ REQUEST_CONTEXT, e);
1166 } 1166 }
1167 return cronetEngine; 1167 return cronetEngine;
1168 } 1168 }
1169 1169
1170 /** 1170 /**
1171 * Registers a listener that gets called after the end of each request with the request info. 1171 * Registers a listener that gets called after the end of each request with the request info.
1172 * 1172 *
1173 * <p>This must be called after {@link #enableNetworkQualityEstimator} and w ill throw an 1173 * <p>The listener is called on an {@link java.util.concurrent.Executor} pro vided by the
1174 * exception otherwise. 1174 * listener.
1175 *
1176 * <p>The listener is called on the {@link java.util.concurrent.Executor} th at
1177 * is passed to {@link #enableNetworkQualityEstimator}.
1178 * 1175 *
1179 * @param listener the listener for finished requests. 1176 * @param listener the listener for finished requests.
1180 * 1177 *
1181 * @hide as it's a prototype. 1178 * @hide as it's a prototype.
1182 */ 1179 */
1183 public abstract void addRequestFinishedListener(RequestFinishedInfo.Listener listener); 1180 public abstract void addRequestFinishedListener(RequestFinishedInfo.Listener listener);
1184 1181
1185 /** 1182 /**
1186 * Removes a finished request listener. 1183 * Removes a finished request listener.
1187 * 1184 *
(...skipping 12 matching lines...) Expand all
1200 * 1197 *
1201 * @param url URL for the generated requests. 1198 * @param url URL for the generated requests.
1202 * @param callback callback object that gets invoked on different events. 1199 * @param callback callback object that gets invoked on different events.
1203 * @param executor {@link Executor} on which all callbacks will be invoked. 1200 * @param executor {@link Executor} on which all callbacks will be invoked.
1204 */ 1201 */
1205 public UrlRequest.Builder newUrlRequestBuilder( 1202 public UrlRequest.Builder newUrlRequestBuilder(
1206 String url, UrlRequest.Callback callback, Executor executor) { 1203 String url, UrlRequest.Callback callback, Executor executor) {
1207 return new UrlRequest.Builder(url, callback, executor, this); 1204 return new UrlRequest.Builder(url, callback, executor, this);
1208 } 1205 }
1209 } 1206 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698