Index: net/url_request/url_request_status.h |
diff --git a/net/url_request/url_request_status.h b/net/url_request/url_request_status.h |
index 44a5d22bf04cdbfe736f08f80e42c22a1111acbe..b6641dd3af454c896831eeaa35eca21dfc7a21a3 100644 |
--- a/net/url_request/url_request_status.h |
+++ b/net/url_request/url_request_status.h |
@@ -5,6 +5,7 @@ |
#ifndef NET_URL_REQUEST_URL_REQUEST_STATUS_H_ |
#define NET_URL_REQUEST_URL_REQUEST_STATUS_H_ |
+#include "net/base/net_errors.h" |
#include "net/base/net_export.h" |
namespace net { |
@@ -41,6 +42,13 @@ class NET_EXPORT URLRequestStatus { |
// deprecated. See https://crbug.com/490311. |
static URLRequestStatus FromError(int error); |
+ // Returns a net::Error corresponding to |status_|. |
+ // net::OK for OK |
+ // net::ERR_IO_PENDING for IO_PENDING |
+ // net::ERR_ABORTED for CANCELLED |
+ // net::Error for FAILED |
+ net::Error ToNetError() const; |
mmenke
2015/10/27 19:41:08
Remove net::
xunjieli
2015/10/27 21:24:07
Done.
|
+ |
Status status() const { return status_; } |
int error() const { return error_; } |