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

Unified Diff: net/base/upload_data_stream.h

Issue 2227503003: Add net log to UploadDataStream. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: typo Created 4 years, 4 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
« no previous file with comments | « net/base/elements_upload_data_stream_unittest.cc ('k') | net/base/upload_data_stream.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/base/upload_data_stream.h
diff --git a/net/base/upload_data_stream.h b/net/base/upload_data_stream.h
index b3f360ef67f16bc83b2d1ad42185483d2d5bea41..9c269613e6952436c8cbd5ded1f309830c5816ab 100644
--- a/net/base/upload_data_stream.h
+++ b/net/base/upload_data_stream.h
@@ -13,6 +13,7 @@
#include "base/macros.h"
#include "net/base/completion_callback.h"
#include "net/base/net_export.h"
+#include "net/log/net_log.h"
namespace net {
@@ -43,7 +44,7 @@ class NET_EXPORT UploadDataStream {
// Returns OK on success. Returns ERR_UPLOAD_FILE_CHANGED if the expected
// file modification time is set (usually not set, but set for sliced
// files) and the target file is changed.
- int Init(const CompletionCallback& callback);
+ int Init(const CompletionCallback& callback, const BoundNetLog& net_log);
// When possible, reads up to |buf_len| bytes synchronously from the upload
// data stream to |buf| and returns the number of bytes read; otherwise,
@@ -107,7 +108,7 @@ class NET_EXPORT UploadDataStream {
// See Init(). If it returns ERR_IO_PENDING, OnInitCompleted must be called
// once it completes. If the upload is not chunked, SetSize must be called
// before it completes.
- virtual int InitInternal() = 0;
+ virtual int InitInternal(const BoundNetLog& net_log) = 0;
// See Read(). For chunked uploads, must call SetIsFinalChunk if this is the
// final chunk. For non-chunked uploads, the UploadDataStream determins which
@@ -135,6 +136,8 @@ class NET_EXPORT UploadDataStream {
CompletionCallback callback_;
+ BoundNetLog net_log_;
+
DISALLOW_COPY_AND_ASSIGN(UploadDataStream);
};
« no previous file with comments | « net/base/elements_upload_data_stream_unittest.cc ('k') | net/base/upload_data_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698