Chromium Code Reviews| Index: chrome/browser/google_apis/gdata_wapi_operations.h |
| diff --git a/chrome/browser/google_apis/gdata_wapi_operations.h b/chrome/browser/google_apis/gdata_wapi_operations.h |
| index 147d3edf7260dc58b3e4f6af37e75465bb80cb3b..6c9079e79729d0c03ffb32ce568beb7ca4bda17a 100644 |
| --- a/chrome/browser/google_apis/gdata_wapi_operations.h |
| +++ b/chrome/browser/google_apis/gdata_wapi_operations.h |
| @@ -566,6 +566,38 @@ class ResumeUploadOperation : public UploadRangeOperationBase { |
| DISALLOW_COPY_AND_ASSIGN(ResumeUploadOperation); |
| }; |
| +//========================== GetUploadStatusOperation ========================== |
| + |
| +// This class performs the operation for getting the current upload status |
| +// of a file. This operation calls |callback| given via the constructor |
|
satorux1
2013/02/07 06:54:13
Let's drop " given via the constructor" as it's ob
hidehiko
2013/02/07 07:44:07
Done.
|
| +// with the range of the successfully uploaded data, or HTTP_SUCCESS or |
|
satorux1
2013/02/07 06:54:13
maybe it's cleaner to describe the two case separa
hidehiko
2013/02/07 07:44:07
Updated a bit more. How about this?
|
| +// HTTP_CREATED if the whole data is uploaded successfully. |
| +class GetUploadStatusOperation : public UploadRangeOperationBase { |
| + public: |
| + // |callback| must not be null. See also UploadRangeOperationBase's |
| + // constructor for more details. |
| + // |content_length| is the whole data size to be uploaded, or -1 if it is |
| + // unknown. |
| + GetUploadStatusOperation( |
| + OperationRegistry* registry, |
| + net::URLRequestContextGetter* url_request_context_getter, |
| + const UploadRangeCallback& callback, |
|
satorux1
2013/02/07 06:54:13
BTW, UploadRangeCallback takes scoped_ptr<Resource
hidehiko
2013/02/07 07:44:07
The ResourceEntry is used actually. Please see als
satorux1
2013/02/07 07:58:59
I thought ResourceEntry was necessary for ResumeUp
hidehiko
2013/02/07 08:37:56
Acknowledged.
|
| + UploadMode load_mode, |
| + const FilePath& drive_file_path, |
| + const GURL& upload_url, |
| + int64 content_length); |
| + virtual ~GetUploadStatusOperation(); |
| + |
| + protected: |
| + // UrlFetchOperationBase overrides. |
| + virtual std::vector<std::string> GetExtraRequestHeaders() const OVERRIDE; |
| + |
| + private: |
| + const int64 content_length_; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(GetUploadStatusOperation); |
| +}; |
| + |
| } // namespace google_apis |
| #endif // CHROME_BROWSER_GOOGLE_APIS_GDATA_WAPI_OPERATIONS_H_ |