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

Unified Diff: components/cronet/android/java/src/org/chromium/net/UrlRequest.java

Issue 586143002: Initial implementation of Cronet Async API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address Helen's comments, add CronetUrlRequestContextTest. Created 6 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 side-by-side diff with in-line comments
Download patch
Index: components/cronet/android/java/src/org/chromium/net/UrlRequest.java
diff --git a/components/cronet/android/java/src/org/chromium/net/UrlRequest.java b/components/cronet/android/java/src/org/chromium/net/UrlRequest.java
index 57a0b439101592235c74d522962acc76dd9dba37..8df71266f519361a9597ba21500bd8f89d763a32 100644
--- a/components/cronet/android/java/src/org/chromium/net/UrlRequest.java
+++ b/components/cronet/android/java/src/org/chromium/net/UrlRequest.java
@@ -9,6 +9,16 @@ package org.chromium.net;
* Note: All methods must be called on the Executor passed in during creation.
*/
public interface UrlRequest {
+ public static final int REQUEST_PRIORITY_IDLE = 0;
+
+ public static final int REQUEST_PRIORITY_LOWEST = 1;
+
+ public static final int REQUEST_PRIORITY_LOW = 2;
+
+ public static final int REQUEST_PRIORITY_MEDIUM = 3;
+
+ public static final int REQUEST_PRIORITY_HIGHEST = 4;
+
/**
* More setters go here. They may only be called before start (Maybe
* also allow during redirects). Could optionally instead use arguments
@@ -35,9 +45,8 @@ public interface UrlRequest {
/**
* Starts the request, all callbacks go to listener.
- * @param listener
*/
- public void start(UrlRequestListener listener);
+ public void start();
/**
* Can be called at any time.

Powered by Google App Engine
This is Rietveld 408576698