| Index: content/browser/download/download_item.h
|
| diff --git a/content/browser/download/download_item.h b/content/browser/download/download_item.h
|
| index 3592d529f320dc5f903458dcc412b71c6e67385e..671985d94425a72ea894fd07be531758d631d771 100644
|
| --- a/content/browser/download/download_item.h
|
| +++ b/content/browser/download/download_item.h
|
| @@ -124,8 +124,10 @@ class CONTENT_EXPORT DownloadItem {
|
| // Called when the user has validated the download of a dangerous file.
|
| virtual void DangerousDownloadValidated() = 0;
|
|
|
| - // Received a new chunk of data
|
| - virtual void Update(int64 bytes_so_far) = 0;
|
| + // Received a new chunk of data.
|
| + // |bytes_so_far| is the number of bytes received so far.
|
| + // |hash_state| is the current hash state.
|
| + virtual void Update(int64 bytes_so_far, const std::string& hash_state) = 0;
|
|
|
| // Cancel the download operation. We need to distinguish between cancels at
|
| // exit (DownloadManager destructor) from user interface initiated cancels
|
| @@ -154,8 +156,11 @@ class CONTENT_EXPORT DownloadItem {
|
|
|
| // Download operation had an error.
|
| // |size| is the amount of data received at interruption.
|
| + // |hash_state| is the current hash state at interruption.
|
| // |reason| is the download interrupt reason code that the operation received.
|
| - virtual void Interrupted(int64 size, InterruptReason reason) = 0;
|
| + virtual void Interrupted(int64 size,
|
| + const std::string& hash_state,
|
| + InterruptReason reason) = 0;
|
|
|
| // Deletes the file from disk and removes the download from the views and
|
| // history. |user| should be true if this is the result of the user clicking
|
| @@ -240,6 +245,7 @@ class CONTENT_EXPORT DownloadItem {
|
| virtual int64 GetTotalBytes() const = 0;
|
| virtual void SetTotalBytes(int64 total_bytes) = 0;
|
| virtual int64 GetReceivedBytes() const = 0;
|
| + virtual const std::string& GetHashState() const = 0;
|
| virtual int32 GetId() const = 0;
|
| virtual DownloadId GetGlobalId() const = 0;
|
| virtual base::Time GetStartTime() const = 0;
|
| @@ -268,6 +274,9 @@ class CONTENT_EXPORT DownloadItem {
|
| virtual void SetOpened(bool opened) = 0;
|
| virtual bool GetOpened() const = 0;
|
|
|
| + virtual const std::string& GetLastModifiedTime() const = 0;
|
| + virtual const std::string& GetETag() const = 0;
|
| +
|
| virtual InterruptReason GetLastReason() const = 0;
|
| virtual DownloadPersistentStoreInfo GetPersistentStoreInfo() const = 0;
|
| virtual DownloadStateInfo GetStateInfo() const = 0;
|
|
|